diff options
author | Azzurrio <just.azzurri@gmail.com> | 2016-07-26 23:46:03 +0200 |
---|---|---|
committer | Azzurrio <just.azzurri@gmail.com> | 2016-07-28 04:12:15 +0200 |
commit | 80e825915c7ff638f4b668a7cca1be46903cb433 (patch) | |
tree | a6cc267cad01a1d639358f3156e61cc678bd11be /activejob/lib | |
parent | a64d9835f11ea7919fae825bceb91e08a1480766 (diff) | |
download | rails-80e825915c7ff638f4b668a7cca1be46903cb433.tar.gz rails-80e825915c7ff638f4b668a7cca1be46903cb433.tar.bz2 rails-80e825915c7ff638f4b668a7cca1be46903cb433.zip |
Fix accessing provider_job_id inside active jobs for sidekiq adapter
Diffstat (limited to 'activejob/lib')
-rw-r--r-- | activejob/lib/active_job/core.rb | 1 | ||||
-rw-r--r-- | activejob/lib/active_job/queue_adapters/sidekiq_adapter.rb | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/activejob/lib/active_job/core.rb b/activejob/lib/active_job/core.rb index f7f882c998..f0606b3834 100644 --- a/activejob/lib/active_job/core.rb +++ b/activejob/lib/active_job/core.rb @@ -105,6 +105,7 @@ module ActiveJob # end def deserialize(job_data) self.job_id = job_data['job_id'] + self.provider_job_id = job_data['provider_job_id'] self.queue_name = job_data['queue_name'] self.priority = job_data['priority'] self.serialized_arguments = job_data['arguments'] diff --git a/activejob/lib/active_job/queue_adapters/sidekiq_adapter.rb b/activejob/lib/active_job/queue_adapters/sidekiq_adapter.rb index c321776bf5..3d33b3923b 100644 --- a/activejob/lib/active_job/queue_adapters/sidekiq_adapter.rb +++ b/activejob/lib/active_job/queue_adapters/sidekiq_adapter.rb @@ -37,7 +37,7 @@ module ActiveJob include Sidekiq::Worker def perform(job_data) - Base.execute job_data + Base.execute job_data.merge('provider_job_id' => jid) end end end |