ee/lib/gitlab/geo/file_downloader.rb
# Executes the actual file download
#
# Subclasses should return the number of bytes downloaded,
# or nil or -1 if a failure occurred.
Executes the actual file download
Subclasses should return the number of bytes downloaded,
or nil or -1 if a failure occurred.
Executes the actual file download Subclasses should return the number of bytes downloaded or nil or - 1 if a failure occurred .
def execute
        upload = Upload.find_by(id: object_db_id)
        return fail_before_transfer unless upload.present?
        transfer = ::Gitlab::Geo::FileTransfer.new(object_type.to_sym, upload)
        Result.from_transfer_result(transfer.download_from_primary)
      end
def execute upload = Upload . find_by ( id : object_db_id ) return fail_before_transfer unless upload . present? transfer = :: Gitlab :: Geo :: FileTransfer . new ( object_type . to_sym , upload ) Result . from_transfer_result ( transfer . download_from_primary ) end
Executes the actual file download
Subclasses should return the number of bytes downloaded,
or nil or -1 if a failure occurred.
Executes the actual file download Subclasses should return the number of bytes downloaded or nil or - 1 if a failure occurred .