Class: Gitlab::Ci::Pipeline::Chain::Create
- Includes:
- Helpers
- Defined in:
- lib/gitlab/ci/pipeline/chain/create.rb
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
Methods included from Helpers
#error, #persist_pipeline?, #warning
Methods inherited from Base
Constructor Details
This class inherits a constructor from Gitlab::Ci::Pipeline::Chain::Base
Instance Method Details
#break? ⇒ Boolean
18 19 20 |
# File 'lib/gitlab/ci/pipeline/chain/create.rb', line 18 def break? !pipeline.persisted? end |
#perform! ⇒ Object
10 11 12 13 14 15 16 |
# File 'lib/gitlab/ci/pipeline/chain/create.rb', line 10 def perform! BulkInsertableAssociations.with_bulk_insert(enabled: ::Gitlab::Ci::Features.bulk_insert_on_create?(project)) do pipeline.save! end rescue ActiveRecord::RecordInvalid => e error("Failed to persist the pipeline: #{e}") end |