Class: ClickHouse::MigrationSupport::SidekiqMiddleware
- Inherits:
-
Object
- Object
- ClickHouse::MigrationSupport::SidekiqMiddleware
- Defined in:
- lib/click_house/migration_support/sidekiq_middleware.rb
Instance Method Summary collapse
Instance Method Details
#call(worker, job, queue) ⇒ Object
6 7 8 9 10 11 12 |
# File 'lib/click_house/migration_support/sidekiq_middleware.rb', line 6 def call(worker, job, queue) return yield unless register_worker?(worker.class) ::ClickHouse::MigrationSupport::ExclusiveLock.register_running_worker(worker.class, worker_id(job, queue)) do yield end end |