sidekiq-unique-jobs 7.1.5 → 7.1.6
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of sidekiq-unique-jobs might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/CHANGELOG.md +9 -1
- data/README.md +1 -1
- data/lib/sidekiq_unique_jobs/lock/base_lock.rb +1 -0
- data/lib/sidekiq_unique_jobs/sidekiq_unique_ext.rb +35 -13
- data/lib/sidekiq_unique_jobs/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: db3824ece0f3732be10713c17098f95b761b2e8ae5b710842344393645cea160
|
4
|
+
data.tar.gz: ec03e4ecf107710aa4ff3007313fde1cc558b7f2f4d577cc3ec357c0580eb869
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c03ff9a5fb1f30cf61181b97286f896203c7b32ed591f0b920bac9d8461402e2a7cdcf32b0a1c92488b15c01ba56631a1aec48c0e4ff73a76bf0187a3b22ef91
|
7
|
+
data.tar.gz: 35447b5dc1536ba8e8f4e310e15356238cd6e78e7f76d239ef11ea90c05d5a0d397fa8f1092649cc3eeea317676a0d9fe67a09c650be0238b615e3e232b58b9b
|
data/CHANGELOG.md
CHANGED
@@ -1,10 +1,18 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
## [v7.1.5](https://github.com/mhenrixon/sidekiq-unique-jobs/tree/v7.1.5) (2021-07-28)
|
4
|
+
|
5
|
+
[Full Changelog](https://github.com/mhenrixon/sidekiq-unique-jobs/compare/v7.1.4...v7.1.5)
|
6
|
+
|
7
|
+
**Fixed bugs:**
|
8
|
+
|
9
|
+
- Fix: UntilAndWhileExecuting [\#627](https://github.com/mhenrixon/sidekiq-unique-jobs/pull/627) ([mhenrixon](https://github.com/mhenrixon))
|
10
|
+
|
3
11
|
## [v7.1.4](https://github.com/mhenrixon/sidekiq-unique-jobs/tree/v7.1.4) (2021-07-21)
|
4
12
|
|
5
13
|
[Full Changelog](https://github.com/mhenrixon/sidekiq-unique-jobs/compare/v7.1.3...v7.1.4)
|
6
14
|
|
7
|
-
**
|
15
|
+
**Fixed bugs:**
|
8
16
|
|
9
17
|
- Pass lock timeout to primed\_async [\#624](https://github.com/mhenrixon/sidekiq-unique-jobs/pull/624) ([millerjs](https://github.com/millerjs))
|
10
18
|
|
data/README.md
CHANGED
@@ -268,7 +268,7 @@ end
|
|
268
268
|
|
269
269
|
### While Executing
|
270
270
|
|
271
|
-
|
271
|
+
These locks are put on a queue without any type of locking mechanism, the locking doesn't happen until Sidekiq pops the job from the queue and starts processing it.
|
272
272
|
|
273
273
|
#### Example worker
|
274
274
|
|
@@ -68,24 +68,46 @@ module Sidekiq
|
|
68
68
|
prepend UniqueExtension
|
69
69
|
end
|
70
70
|
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
# Provides extensions for unlocking jobs that are removed and deleted
|
75
|
-
#
|
76
|
-
# @author Mikael Henriksson <mikael@mhenrixon.com>
|
77
|
-
#
|
78
|
-
module UniqueExtension
|
71
|
+
if Sidekiq.const_defined?("JobRecord")
|
72
|
+
# See Sidekiq::Api
|
73
|
+
class JobRecord
|
79
74
|
#
|
80
|
-
#
|
75
|
+
# Provides extensions for unlocking jobs that are removed and deleted
|
81
76
|
#
|
82
|
-
|
83
|
-
|
84
|
-
|
77
|
+
# @author Mikael Henriksson <mikael@mhenrixon.com>
|
78
|
+
#
|
79
|
+
module UniqueExtension
|
80
|
+
#
|
81
|
+
# Wraps the original method to ensure locks for the job are deleted
|
82
|
+
#
|
83
|
+
def delete
|
84
|
+
SidekiqUniqueJobs::Unlockable.delete!(item)
|
85
|
+
super
|
86
|
+
end
|
85
87
|
end
|
88
|
+
|
89
|
+
prepend UniqueExtension
|
86
90
|
end
|
91
|
+
else
|
92
|
+
# See Sidekiq::Api
|
93
|
+
class Job
|
94
|
+
#
|
95
|
+
# Provides extensions for unlocking jobs that are removed and deleted
|
96
|
+
#
|
97
|
+
# @author Mikael Henriksson <mikael@mhenrixon.com>
|
98
|
+
#
|
99
|
+
module UniqueExtension
|
100
|
+
#
|
101
|
+
# Wraps the original method to ensure locks for the job are deleted
|
102
|
+
#
|
103
|
+
def delete
|
104
|
+
SidekiqUniqueJobs::Unlockable.delete!(item)
|
105
|
+
super
|
106
|
+
end
|
107
|
+
end
|
87
108
|
|
88
|
-
|
109
|
+
prepend UniqueExtension
|
110
|
+
end
|
89
111
|
end
|
90
112
|
|
91
113
|
# See Sidekiq::Api
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sidekiq-unique-jobs
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 7.1.
|
4
|
+
version: 7.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mikael Henriksson
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-09-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: brpoplpush-redis_script
|
@@ -261,7 +261,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
261
261
|
- !ruby/object:Gem::Version
|
262
262
|
version: '0'
|
263
263
|
requirements: []
|
264
|
-
rubygems_version: 3.2.
|
264
|
+
rubygems_version: 3.2.27
|
265
265
|
signing_key:
|
266
266
|
specification_version: 4
|
267
267
|
summary: Sidekiq middleware that prevents duplicates jobs
|