activejob-uniqueness 0.2.5 → 0.3.0

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
2
  SHA256:
3
- metadata.gz: 9554ab5de5c83f0af7528f4618155b8cd4b68673760fdc7c6113bce6fd2f2f53
4
- data.tar.gz: 69849f32a26a29f2c644c2a6749c7ca45221f2d04650d369880a2e5050005d0f
3
+ metadata.gz: 705386dd2f0c394a53f42b2051dfde2545ed65f74dc1a54f4a177a9f89bcb385
4
+ data.tar.gz: 41ae721426c8e02035f8150fd5be55f63d645f3df0cdb39c6f5119cf06d6e2cd
5
5
  SHA512:
6
- metadata.gz: c661da1de663277171fd5d8fff5a89f54c1dee158c26383863b359439e64e3a29d4d4a611ec16a6e7e13c953eea1abce017d225e242a9877a423ffd8a1aaa486
7
- data.tar.gz: 4300874d054bb6b33eb0e6960fe63c2497b193e6cca64e32bf2b77a3d886c21919478e915434f995855f625cacc36155be0519fc296026de5a7cd2cad5038795
6
+ metadata.gz: 0fac130eadc83e0aee35567aa7e1f780bc1086b61eb658af01576672d5023bbc82cf2f97faef5429770dd4b26645973fba010bb1df69eee9b606f5307aafe734
7
+ data.tar.gz: 238eddea7dccfcb9c00e863872c837747ccafe2c4df8ecc12085ceb85dc843551f791889b05f4c0e3b1b890efe4c69c74ecca3875c23feaeb9fd783baf69e57d
data/CHANGELOG.md CHANGED
@@ -3,9 +3,20 @@ All notable changes to this project will be documented in this file.
3
3
 
4
4
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
5
5
 
6
- ## [Unreleased](https://github.com/veeqo/activejob-uniqueness/compare/v0.2.5...HEAD)
6
+ ## [Unreleased](https://github.com/veeqo/activejob-uniqueness/compare/v0.3.0...HEAD)
7
7
 
8
8
 
9
+ ## [0.3.0](https://github.com/veeqo/activejob-uniqueness/compare/v0.2.5...v0.3.0) - 2023-10-20
10
+
11
+ ### Added
12
+ - [#66](https://github.com/veeqo/activejob-uniqueness/pull/66) Activejob 7.1 support by [@laurafeier](https://github.com/laurafeier)
13
+
14
+ ### Changed
15
+ - [#57](https://github.com/veeqo/activejob-uniqueness/pull/57) Upgrade to Redlock 2 & use redis-client by [@bmulholland](https://github.com/bmulholland)
16
+
17
+ ### Removed
18
+ - Support fo Redlock v1 is removed. Switching to `RedisClient` is [a breaking change of Redlock v2](https://github.com/leandromoreira/redlock-rb/blob/main/CHANGELOG.md#200---2023-02-09).
19
+
9
20
  ## [0.2.5](https://github.com/veeqo/activejob-uniqueness/compare/v0.2.4...v0.2.5) - 2023-02-01
10
21
 
11
22
  ### Added
@@ -10,7 +10,7 @@ module ActiveJob
10
10
  def delete_lock(resource)
11
11
  @servers.each do |server|
12
12
  server.instance_variable_get(:@redis).with do |conn|
13
- conn.del resource
13
+ conn.call('DEL', resource)
14
14
  end
15
15
  end
16
16
 
@@ -21,7 +21,7 @@ module ActiveJob
21
21
  def delete_locks(wildcard)
22
22
  @servers.each do |server|
23
23
  server.instance_variable_get(:@redis).with do |conn|
24
- conn.scan_each(match: wildcard).each { |key| conn.del key }
24
+ conn.scan('MATCH', wildcard).each { |key| conn.call('DEL', key) }
25
25
  end
26
26
  end
27
27
 
@@ -2,6 +2,6 @@
2
2
 
3
3
  module ActiveJob
4
4
  module Uniqueness
5
- VERSION = '0.2.5'
5
+ VERSION = '0.3.0'
6
6
  end
7
7
  end
@@ -2,7 +2,7 @@
2
2
 
3
3
  ActiveJob::Uniqueness.configure do |config|
4
4
  # Global default expiration for lock keys. Each job can define its own ttl via :lock_ttl option.
5
- # Stategy :until_and_while_executing also accept :on_runtime_ttl option.
5
+ # Strategy :until_and_while_executing also accepts :on_runtime_ttl option.
6
6
  #
7
7
  # config.lock_ttl = 1.day
8
8
 
@@ -11,7 +11,7 @@ ActiveJob::Uniqueness.configure do |config|
11
11
  # config.lock_prefix = 'activejob_uniqueness'
12
12
 
13
13
  # Default action on lock conflict. Can be set per job.
14
- # Stategy :until_and_while_executing also accept :on_runtime_conflict option.
14
+ # Strategy :until_and_while_executing also accepts :on_runtime_conflict option.
15
15
  # Allowed values are
16
16
  # :raise - raises ActiveJob::Uniqueness::JobNotUnique
17
17
  # :log - instruments ActiveSupport::Notifications and logs event to the ActiveJob::Logger
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: activejob-uniqueness
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.5
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rustam Sharshenov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-02-01 00:00:00.000000000 Z
11
+ date: 2023-10-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activejob
@@ -19,7 +19,7 @@ dependencies:
19
19
  version: '4.2'
20
20
  - - "<"
21
21
  - !ruby/object:Gem::Version
22
- version: '7.1'
22
+ version: '7.2'
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
@@ -29,27 +29,27 @@ dependencies:
29
29
  version: '4.2'
30
30
  - - "<"
31
31
  - !ruby/object:Gem::Version
32
- version: '7.1'
32
+ version: '7.2'
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: redlock
35
35
  requirement: !ruby/object:Gem::Requirement
36
36
  requirements:
37
37
  - - ">="
38
38
  - !ruby/object:Gem::Version
39
- version: '1.2'
39
+ version: '2.0'
40
40
  - - "<"
41
41
  - !ruby/object:Gem::Version
42
- version: '2'
42
+ version: '3'
43
43
  type: :runtime
44
44
  prerelease: false
45
45
  version_requirements: !ruby/object:Gem::Requirement
46
46
  requirements:
47
47
  - - ">="
48
48
  - !ruby/object:Gem::Version
49
- version: '1.2'
49
+ version: '2.0'
50
50
  - - "<"
51
51
  - !ruby/object:Gem::Version
52
- version: '2'
52
+ version: '3'
53
53
  - !ruby/object:Gem::Dependency
54
54
  name: appraisal
55
55
  requirement: !ruby/object:Gem::Requirement
@@ -82,16 +82,16 @@ dependencies:
82
82
  name: pry-byebug
83
83
  requirement: !ruby/object:Gem::Requirement
84
84
  requirements:
85
- - - ">="
85
+ - - ">"
86
86
  - !ruby/object:Gem::Version
87
- version: '0'
87
+ version: 3.6.0
88
88
  type: :development
89
89
  prerelease: false
90
90
  version_requirements: !ruby/object:Gem::Requirement
91
91
  requirements:
92
- - - ">="
92
+ - - ">"
93
93
  - !ruby/object:Gem::Version
94
- version: '0'
94
+ version: 3.6.0
95
95
  - !ruby/object:Gem::Dependency
96
96
  name: rspec
97
97
  requirement: !ruby/object:Gem::Requirement
@@ -187,7 +187,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
187
187
  - !ruby/object:Gem::Version
188
188
  version: '0'
189
189
  requirements: []
190
- rubygems_version: 3.1.6
190
+ rubygems_version: 3.2.33
191
191
  signing_key:
192
192
  specification_version: 4
193
193
  summary: Ensure uniqueness of your ActiveJob jobs