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
|
|
|
|
|
|
|
|
def perform
|
2019-12-16 22:33:55 +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
|