active_job_resque_solo 0.3.1.pre → 0.3.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +4 -2
- data/CHANGELOG.md +4 -0
- data/active_job_resque_solo.gemspec +3 -1
- data/lib/active_job/plugins/resque/solo/lock.rb +1 -9
- data/lib/active_job_resque_solo/version.rb +1 -1
- metadata +8 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3389e5a4e6baa27ff036950fe7d33481f11e2e4e
|
4
|
+
data.tar.gz: 6a35295a25a4dec30449fdfb37233b3e1eabd2df
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 21adde8385e257074f4fe58088ea3ea99eadecd6b48591445feece329c7a6edb06288c60076c2b04970956436df3a74f62abfcc9cd5602acb99861473ab92633
|
7
|
+
data.tar.gz: 1cb85b9a297521eec7360dc423fd64e2d6f2768a23605b6bd3a35158f84f9bd7dd5b6449d36bf1ef7b271cfa052857153d22f45abc88b7c8371b34ecbfdb95ba
|
data/.travis.yml
CHANGED
data/CHANGELOG.md
CHANGED
@@ -10,7 +10,7 @@ Gem::Specification.new do |spec|
|
|
10
10
|
spec.email = ["kinkadep@gmail.com"]
|
11
11
|
|
12
12
|
spec.summary = %q{Prevents duplicate ActiveJob+Resque jobs from being enqueued.}
|
13
|
-
spec.description = %q{If you are using ActiveJob with the Resque Adapter, this gem will
|
13
|
+
spec.description = %q{If you are using ActiveJob with the Resque Adapter, this gem will prevent a jobs, based on arguments, from being enqueued to Resque as long as a duplicate is already in queue or executing on a worker.}
|
14
14
|
spec.license = "MIT"
|
15
15
|
spec.homepage = "https://github.com/kinkade/active_job_resque_solo"
|
16
16
|
|
@@ -22,6 +22,8 @@ Gem::Specification.new do |spec|
|
|
22
22
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
23
23
|
spec.require_paths = ["lib"]
|
24
24
|
|
25
|
+
spec.required_ruby_version = ">= 2.2.0"
|
26
|
+
|
25
27
|
spec.add_dependency "rails", ">= 4.2.0", "< 6"
|
26
28
|
|
27
29
|
spec.add_development_dependency "byebug"
|
@@ -42,17 +42,9 @@ module ActiveJob
|
|
42
42
|
|
43
43
|
if @redis.set(@key, @uuid, px: px, nx: true)
|
44
44
|
@acquired = @uuid
|
45
|
-
else
|
46
|
-
extend_at = Time.now.utc
|
47
|
-
@acquired = @redis.get(@key)
|
48
45
|
end
|
49
46
|
|
50
|
-
|
51
|
-
# that another process has acquired the lock.
|
52
|
-
#
|
53
|
-
# It is unlikely that acquired will be nil, but
|
54
|
-
# it is possible if Redis is slow due to extreme load.
|
55
|
-
(@acquired.nil? || @acquired == @uuid) ? extend_at : nil
|
47
|
+
@acquired == @uuid ? extend_at : nil
|
56
48
|
end
|
57
49
|
|
58
50
|
def extend
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: active_job_resque_solo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Phillip Kinkade
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-09-
|
11
|
+
date: 2017-09-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -86,8 +86,9 @@ dependencies:
|
|
86
86
|
- - ">="
|
87
87
|
- !ruby/object:Gem::Version
|
88
88
|
version: '0'
|
89
|
-
description: If you are using ActiveJob with the Resque Adapter, this gem will
|
90
|
-
|
89
|
+
description: If you are using ActiveJob with the Resque Adapter, this gem will prevent
|
90
|
+
a jobs, based on arguments, from being enqueued to Resque as long as a duplicate
|
91
|
+
is already in queue or executing on a worker.
|
91
92
|
email:
|
92
93
|
- kinkadep@gmail.com
|
93
94
|
executables: []
|
@@ -123,12 +124,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
123
124
|
requirements:
|
124
125
|
- - ">="
|
125
126
|
- !ruby/object:Gem::Version
|
126
|
-
version:
|
127
|
+
version: 2.2.0
|
127
128
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
128
129
|
requirements:
|
129
|
-
- - "
|
130
|
+
- - ">="
|
130
131
|
- !ruby/object:Gem::Version
|
131
|
-
version:
|
132
|
+
version: '0'
|
132
133
|
requirements: []
|
133
134
|
rubyforge_project:
|
134
135
|
rubygems_version: 2.6.6
|