summaryrefslogtreecommitdiff
path: root/app/services/ci/pipeline_processing/atomic_processing_service.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/services/ci/pipeline_processing/atomic_processing_service.rb')
-rw-r--r--app/services/ci/pipeline_processing/atomic_processing_service.rb9
1 files changed, 5 insertions, 4 deletions
diff --git a/app/services/ci/pipeline_processing/atomic_processing_service.rb b/app/services/ci/pipeline_processing/atomic_processing_service.rb
index 508d9c3f2e1..2b8eb104be5 100644
--- a/app/services/ci/pipeline_processing/atomic_processing_service.rb
+++ b/app/services/ci/pipeline_processing/atomic_processing_service.rb
@@ -42,13 +42,14 @@ module Ci
end
def update_stages!
- pipeline.stages.ordered.each(&method(:update_stage!))
+ pipeline.stages.ordered.each { |stage| update_stage!(stage) }
end
def update_stage!(stage)
# Update processables for a given stage in bulk/slices
- ids = @collection.created_processable_ids_for_stage_position(stage.position)
- ids.in_groups_of(BATCH_SIZE, false, &method(:update_processables!))
+ @collection
+ .created_processable_ids_for_stage_position(stage.position)
+ .in_groups_of(BATCH_SIZE, false) { |ids| update_processables!(ids) }
status = @collection.status_for_stage_position(stage.position)
stage.set_status(status)
@@ -62,7 +63,7 @@ module Ci
.ordered_by_stage
.select_with_aggregated_needs(project)
- created_processables.each(&method(:update_processable!))
+ created_processables.each { |processable| update_processable!(processable) }
end
def update_pipeline!