bulk_import_worker.rb 282 B

12345678910111213
  1. # frozen_string_literal: true
  2. class BulkImportWorker
  3. include Sidekiq::Worker
  4. sidekiq_options queue: 'pull', retry: false
  5. def perform(import_id)
  6. import = BulkImport.find(import_id)
  7. import.update!(state: :in_progress)
  8. BulkImportService.new.call(import)
  9. end
  10. end