Sha256: c87cf269ee55d0fae12d0c1e3b6370fa4d8a727045ea8768dceb30ae20d9ad2f

Contents?: true

Size: 424 Bytes

Versions: 51

Compression:

Stored size: 424 Bytes

Contents

require_relative './base_job'

module CanvasSync
  module JobBatches
    class ConcurrentBatchJob < BaseJob
      def perform(sub_jobs, context: nil)
        Batch.new.tap do |b|
          b.description = "Concurrent Batch Root"
          b.context = context
          b.jobs do
            sub_jobs.each do |j|
              ChainBuilder.enqueue_job(j)
            end
          end
        end
      end
    end
  end
end

Version data entries

51 entries across 51 versions & 1 rubygems

Version Path
canvas_sync-0.17.0.beta15 lib/canvas_sync/job_batches/jobs/concurrent_batch_job.rb
canvas_sync-0.17.0.beta14 lib/canvas_sync/job_batches/jobs/concurrent_batch_job.rb
canvas_sync-0.17.0.beta13 lib/canvas_sync/job_batches/jobs/concurrent_batch_job.rb
canvas_sync-0.17.0.beta12 lib/canvas_sync/job_batches/jobs/concurrent_batch_job.rb
canvas_sync-0.17.0.beta11 lib/canvas_sync/job_batches/jobs/concurrent_batch_job.rb
canvas_sync-0.17.0.beta10 lib/canvas_sync/job_batches/jobs/concurrent_batch_job.rb
canvas_sync-0.17.0.beta9 lib/canvas_sync/job_batches/jobs/concurrent_batch_job.rb
canvas_sync-0.17.0.beta8 lib/canvas_sync/job_batches/jobs/concurrent_batch_job.rb
canvas_sync-0.17.0.beta7 lib/canvas_sync/job_batches/jobs/concurrent_batch_job.rb
canvas_sync-0.17.0.beta6 lib/canvas_sync/job_batches/jobs/concurrent_batch_job.rb
canvas_sync-0.17.0.beta5 lib/canvas_sync/job_batches/jobs/concurrent_batch_job.rb