debian-mirror-gitlab/app/workers/pipeline_schedule_worker.rb

18 lines
442 B
Ruby
Raw Normal View History

2018-11-08 19:23:39 +05:30
# frozen_string_literal: true
2017-08-17 22:00:37 +05:30
class PipelineScheduleWorker
2018-03-17 18:26:18 +05:30
include ApplicationWorker
2017-08-17 22:00:37 +05:30
include CronjobQueue
2019-07-07 11:18:12 +05:30
2019-12-21 20:55:43 +05:30
feature_category :continuous_integration
2019-12-26 22:10:19 +05:30
worker_resource_boundary :cpu
2019-12-21 20:55:43 +05:30
2017-08-17 22:00:37 +05:30
def perform
2019-09-04 21:01:54 +05:30
Ci::PipelineSchedule.runnable_schedules.preloaded.find_in_batches do |schedules|
schedules.each do |schedule|
Ci::PipelineScheduleService.new(schedule.project, schedule.owner).execute(schedule)
2017-08-17 22:00:37 +05:30
end
end
end
end