active_interaction-active_job 0.3.0 → 0.3.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 9c07d78350fd9b3ccc7e99ad7d238fd7e541f5f3
4
- data.tar.gz: 58ed3d122bf95d64de98b165c3aaa675f55c38cd
2
+ SHA256:
3
+ metadata.gz: '0598ac21103014d92d50f30e78ac3617f1d3ac97a9bbaaee81f20bfb8f3cd6d6'
4
+ data.tar.gz: 199803066524e6aa2b5c0f7b5d3da74bc150e3ac73a841d58b480b1b19e6d740
5
5
  SHA512:
6
- metadata.gz: 794741cffd5a6ed5dac4018e536b6bf5c63d6e7154f03224f6f40f5215d12833375f059ae8ca3cebf736ed3123c52aa7fc70ae62f16d61ef1ede25f236e672f0
7
- data.tar.gz: 39f2e048951ea7201247c747a3b44bf6e9dafd205c95c6d71f867eb36d2cf95da0d56b9cbe8bf1810d5a39e030fb8bfe9200fd4b7b38a0b4116236553ea841b2
6
+ metadata.gz: c21f6ff73ad4055fb7aa53648b7230c603ddba13e03bd8e1749f522412d96e3c4085d130a7584f5b23cf2145b5869fc6a1996c05144b4aabd42c4018221f1325
7
+ data.tar.gz: c7960ee212465127480c723e282845be71b60f09515194027d647970daaa336e93b1f683c3bf1e4b8ca9c9c5d1e6d587875c601946e3d692fd36d817fd0ac59a
@@ -1,3 +1,6 @@
1
+ ### 0.3.1
2
+ - Add support for Sidekiq Enterprise Encryption
3
+
1
4
  ### 0.3.0
2
5
 
3
6
  - **BREAKING CHANGE** `class.async` method is removed, use `delay.run` or alias it yourself
data/README.md CHANGED
@@ -34,8 +34,6 @@ end
34
34
 
35
35
 
36
36
  Add.delay.run(x: 1, y: 2)
37
- Add.async(x: 1, y: 2) # same as above
38
-
39
37
  Add.delay(queue_name: 'fast', wait: 1.week).run(x: 1, y: 2)
40
38
  ```
41
39
 
@@ -88,8 +86,6 @@ end
88
86
 
89
87
 
90
88
  AddOrDivide.delay.run(x: 4, y: 2, divide: true)
91
- AddOrDivide.async(x: 4, y: 2, divide: true) # same as above
92
-
93
89
  AddOrDivide.delay(queue_name: 'fast', wait: 1.week).run(x: 4, y: 2, divide: true)
94
90
  ```
95
91
 
@@ -121,6 +117,8 @@ end
121
117
  Add.delay(wait: 1.minute, queue: 'slow').run
122
118
  ```
123
119
 
120
+ In sidekiq mode `delay` method accepts anything sidekiq `set` [method](https://github.com/mperham/sidekiq/wiki/Advanced-Options#workers) (`queue`, `retry`, `backtrace`, etc) plus two additional: `wait` and `wait_until`.
121
+
124
122
 
125
123
  ## Development
126
124
 
@@ -7,6 +7,10 @@ class ActiveInteraction::ActiveJob::Sidekiq::ConfiguredJob < ::ActiveJob::Config
7
7
  args = ActiveJob::Arguments.serialize(args)
8
8
  scope = @job_class.set(@options.except(:wait, :wait_until))
9
9
 
10
+ if @job_class.sidekiq_options['encrypt']
11
+ args.prepend(nil)
12
+ end
13
+
10
14
  if @options[:wait]
11
15
  scope.perform_in @options[:wait], *args
12
16
  elsif @options[:wait_until]
@@ -1,5 +1,10 @@
1
1
  module ActiveInteraction::ActiveJob::Sidekiq::JobHelper
2
2
  def perform *args
3
+ # support for sidekiq encrypted params
4
+ if args.length > 1 && args[0].nil?
5
+ args.shift
6
+ end
7
+
3
8
  args = ActiveJob::Arguments.deserialize(args)
4
9
  self.class.parent.run!(*args)
5
10
  end
@@ -1,5 +1,5 @@
1
1
  module ActiveInteraction
2
2
  module ActiveJob
3
- VERSION = "0.3.0"
3
+ VERSION = "0.3.1"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_interaction-active_job
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Anton Katunin
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-08-22 00:00:00.000000000 Z
11
+ date: 2019-10-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activejob
@@ -125,8 +125,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
125
125
  - !ruby/object:Gem::Version
126
126
  version: '0'
127
127
  requirements: []
128
- rubyforge_project:
129
- rubygems_version: 2.6.8
128
+ rubygems_version: 3.0.1
130
129
  signing_key:
131
130
  specification_version: 4
132
131
  summary: Add ActiveJob support to ActiveInteraction gem