Sha256: 43e18cd3a26c09be0990f854f9d6b3bd34328b0344a8bc88b2e09fabed001457
Contents?: true
Size: 396 Bytes
Versions: 1
Compression:
Stored size: 396 Bytes
Contents
module AtomicSidekiq module AtomicOperation class Requeue < Base def perform(queue:, job:) redis do |conn| requeue(conn, queue: queue, job: job) end end private def requeue(conn, queue:, job:) conn.multi do conn.rpush(queue, job) conn.del(in_flight_job_key(queue, job)) end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
atomic-sidekiq-1.0.0 | lib/atomic_sidekiq/atomic_operation/requeue.rb |