Class: JobArtifactUploader
- Inherits:
-
GitlabUploader
- Object
- CarrierWave::Uploader::Base
- GitlabUploader
- JobArtifactUploader
- Extended by:
- Workhorse::UploadPath
- Includes:
- ObjectStorage::Concern
- Defined in:
- app/uploaders/job_artifact_uploader.rb
Constant Summary collapse
- UnknownFileLocationError =
Class.new(StandardError)
Constants inherited from GitlabUploader
GitlabUploader::ObjectNotReadyError, GitlabUploader::PROTECTED_METHODS
Instance Method Summary collapse
Methods included from Workhorse::UploadPath
Methods included from ObjectStorage::Concern
#cache!, #delete_migrated_file, #exclusive_lease_key, #exists?, #file_cache_storage?, #file_storage?, #filename, #filename=, #fog_attributes, #fog_credentials, #fog_directory, #fog_public, #migrate!, #object_store, #object_store=, #persist_object_store!, #persist_object_store?, #schedule_background_upload, #store!, #store_dirs, #store_path, #upload_paths, #use_file, #use_open_file
Methods inherited from GitlabUploader
absolute_path, base_dir, #cache_dir, #exists?, #file_cache_storage?, file_storage?, #filename, #initialize, #local_url, #model_valid?, #move_to_cache, #move_to_store, #open, #relative_path, #replace_file_without_saving!, root, storage_options, #url_or_file_path, version, #work_dir
Constructor Details
This class inherits a constructor from GitlabUploader
Instance Method Details
#cached_size ⇒ Object
13 14 15 16 17 |
# File 'app/uploaders/job_artifact_uploader.rb', line 13 def cached_size return model.size if model.size.present? && !model.file_changed? size end |
#store_dir ⇒ Object
19 20 21 |
# File 'app/uploaders/job_artifact_uploader.rb', line 19 def store_dir dynamic_segment end |