Welcome to mirror list, hosted at ThFree Co, Russian Federation.

pipeline_schedule_worker.rb « workers « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 841308611ebba5ba63e2b07ba6916964ba7419bf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# frozen_string_literal: true

class PipelineScheduleWorker
  include ApplicationWorker
  include CronjobQueue # rubocop:disable Scalability/CronWorkerContext

  feature_category :continuous_integration
  worker_resource_boundary :cpu

  def perform
    Ci::PipelineSchedule.runnable_schedules.preloaded.find_in_batches do |schedules|
      schedules.each do |schedule|
        Ci::PipelineScheduleService.new(schedule.project, schedule.owner).execute(schedule)
      end
    end
  end
end