Sha256: ec81aee3a2f5ecb33f4b3004c6f8a82bfe24ef225e192bbac90e8b3b7b1de25b
Contents?: true
Size: 594 Bytes
Versions: 29
Compression:
Stored size: 594 Bytes
Contents
module Searchkick class BulkReindexJob < ActiveJob::Base queue_as { Searchkick.queue_name } def perform(class_name:, record_ids: nil, index_name: nil, method_name: nil, batch_id: nil, min_id: nil, max_id: nil) klass = class_name.constantize index = index_name ? Searchkick::Index.new(index_name, **klass.searchkick_options) : klass.searchkick_index record_ids ||= min_id..max_id index.import_scope( Searchkick.load_records(klass, record_ids), method_name: method_name, batch: true, batch_id: batch_id ) end end end
Version data entries
29 entries across 29 versions & 1 rubygems