delayed_job 4.1.11 → 4.1.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +13 -0
- data/README.md +1 -1
- data/delayed_job.gemspec +1 -1
- data/lib/delayed/backend/job_preparer.rb +2 -0
- data/lib/delayed/backend/shared_spec.rb +7 -2
- data/lib/delayed/compatibility.rb +0 -12
- data/lib/delayed/message_sending.rb +11 -1
- data/spec/worker_spec.rb +1 -1
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e5f3ae184659ada7959790d1028acaa2b8a7559294704bdf264ff3293b1d9536
|
4
|
+
data.tar.gz: ea333a83c85b2009d85ac69376431434560ec4de435571088f350246ed5e8873
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e542cc9f0b42bc332e93bf9aea570172a53cc2c949195fde5fe6c315cd6e04bb06b1190a37cca83368c87e5c0c0955f72b5b6ccf311f780fd9c333b37f45929f
|
7
|
+
data.tar.gz: bf351eb531b87a4d2dc01b1a2af53963ad37c18c555721af8208d764212721ee3ad5d653b9441ae1210e40f83efd7739c77be8d226f4425a11e9571fd3602d90
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,16 @@
|
|
1
|
+
4.1.12 - 2024-08-14
|
2
|
+
=======================
|
3
|
+
* Add missing require for extract_options
|
4
|
+
* Fix rails 7.2 ActiveSupport::ProxyObject deprecation
|
5
|
+
* Multiple contributors on current and legacy test suite improvements
|
6
|
+
|
7
|
+
4.1.12.rc1 - 2024-08-13
|
8
|
+
=======================
|
9
|
+
* Validating trusted publishing release
|
10
|
+
* Add missing require for extract_options
|
11
|
+
* Fix rails 7.2 ActiveSupport::ProxyObject deprecation
|
12
|
+
* Multiple contributors on current and legacy test suite improvements
|
13
|
+
|
1
14
|
4.1.11 - 2022-09-28
|
2
15
|
===================
|
3
16
|
* Fix missing require for Rails 7.0.3+
|
data/README.md
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
**If you're viewing this at https://github.com/collectiveidea/delayed_job,
|
2
2
|
you're reading the documentation for the master branch.
|
3
3
|
[View documentation for the latest release
|
4
|
-
(4.1.
|
4
|
+
(4.1.12).](https://github.com/collectiveidea/delayed_job/tree/v4.1.12)**
|
5
5
|
|
6
6
|
Delayed::Job
|
7
7
|
============
|
data/delayed_job.gemspec
CHANGED
@@ -13,7 +13,7 @@ Gem::Specification.new do |spec|
|
|
13
13
|
spec.require_paths = ['lib']
|
14
14
|
spec.summary = 'Database-backed asynchronous priority queue system -- Extracted from Shopify'
|
15
15
|
spec.test_files = Dir.glob('spec/**/*')
|
16
|
-
spec.version = '4.1.
|
16
|
+
spec.version = '4.1.12'
|
17
17
|
spec.metadata = {
|
18
18
|
'changelog_uri' => 'https://github.com/collectiveidea/delayed_job/blob/master/CHANGELOG.md',
|
19
19
|
'bug_tracker_uri' => 'https://github.com/collectiveidea/delayed_job/issues',
|
@@ -230,7 +230,7 @@ shared_examples_for 'a delayed_job backend' do
|
|
230
230
|
end
|
231
231
|
|
232
232
|
it 'reserves jobs scheduled for the past when time zones are involved' do
|
233
|
-
Time.zone = '
|
233
|
+
Time.zone = 'America/New_York'
|
234
234
|
job = create_job :run_at => described_class.db_time_now - 1.minute
|
235
235
|
expect(described_class.reserve(worker)).to eq(job)
|
236
236
|
end
|
@@ -595,7 +595,12 @@ shared_examples_for 'a delayed_job backend' do
|
|
595
595
|
worker.work_off
|
596
596
|
@job.reload
|
597
597
|
expect(@job.last_error).to match(/did not work/)
|
598
|
-
|
598
|
+
if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.4.0')
|
599
|
+
# Ruby 3.4 produces a more verbose message
|
600
|
+
expect(@job.last_error).to match(/sample_jobs.rb:\d+:in 'ErrorJob#perform'/)
|
601
|
+
else
|
602
|
+
expect(@job.last_error).to match(/sample_jobs.rb:\d+:in `perform'/)
|
603
|
+
end
|
599
604
|
expect(@job.attempts).to eq(1)
|
600
605
|
expect(@job.run_at).to be > Delayed::Job.db_time_now - 10.minutes
|
601
606
|
expect(@job.run_at).to be < Delayed::Job.db_time_now + 10.minutes
|
@@ -3,25 +3,13 @@ require 'active_support/version'
|
|
3
3
|
module Delayed
|
4
4
|
module Compatibility
|
5
5
|
if ActiveSupport::VERSION::MAJOR >= 4
|
6
|
-
require 'active_support/proxy_object'
|
7
|
-
|
8
6
|
def self.executable_prefix
|
9
7
|
'bin'
|
10
8
|
end
|
11
|
-
|
12
|
-
def self.proxy_object_class
|
13
|
-
ActiveSupport::ProxyObject
|
14
|
-
end
|
15
9
|
else
|
16
|
-
require 'active_support/basic_object'
|
17
|
-
|
18
10
|
def self.executable_prefix
|
19
11
|
'script'
|
20
12
|
end
|
21
|
-
|
22
|
-
def self.proxy_object_class
|
23
|
-
ActiveSupport::BasicObject
|
24
|
-
end
|
25
13
|
end
|
26
14
|
end
|
27
15
|
end
|
@@ -1,5 +1,15 @@
|
|
1
1
|
module Delayed
|
2
|
-
class DelayProxy <
|
2
|
+
class DelayProxy < BasicObject
|
3
|
+
# What additional methods exist on BasicObject has changed over time
|
4
|
+
(::BasicObject.instance_methods - [:__id__, :__send__, :instance_eval, :instance_exec]).each do |method|
|
5
|
+
undef_method method
|
6
|
+
end
|
7
|
+
|
8
|
+
# Let DelayProxy raise exceptions.
|
9
|
+
def raise(*args)
|
10
|
+
::Object.send(:raise, *args)
|
11
|
+
end
|
12
|
+
|
3
13
|
def initialize(payload_class, target, options)
|
4
14
|
@payload_class = payload_class
|
5
15
|
@target = target
|
data/spec/worker_spec.rb
CHANGED
@@ -106,7 +106,7 @@ describe Delayed::Worker do
|
|
106
106
|
expect(Delayed::Job).to receive(:reserve).exactly(10).times.and_raise(Exception)
|
107
107
|
worker = Delayed::Worker.new
|
108
108
|
9.times { worker.work_off }
|
109
|
-
expect
|
109
|
+
expect { worker.work_off }.to raise_exception Delayed::FatalBackendError
|
110
110
|
end
|
111
111
|
|
112
112
|
it 'allows the backend to attempt recovery from reservation errors' do
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: delayed_job
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.1.
|
4
|
+
version: 4.1.12
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brandon Keepers
|
@@ -12,10 +12,10 @@ authors:
|
|
12
12
|
- Matt Griffin
|
13
13
|
- Steve Richert
|
14
14
|
- Tobias Lütke
|
15
|
-
autorequire:
|
15
|
+
autorequire:
|
16
16
|
bindir: bin
|
17
17
|
cert_chain: []
|
18
|
-
date:
|
18
|
+
date: 2024-08-14 00:00:00.000000000 Z
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|
21
21
|
name: activesupport
|
@@ -106,7 +106,7 @@ metadata:
|
|
106
106
|
changelog_uri: https://github.com/collectiveidea/delayed_job/blob/master/CHANGELOG.md
|
107
107
|
bug_tracker_uri: https://github.com/collectiveidea/delayed_job/issues
|
108
108
|
source_code_uri: https://github.com/collectiveidea/delayed_job
|
109
|
-
post_install_message:
|
109
|
+
post_install_message:
|
110
110
|
rdoc_options: []
|
111
111
|
require_paths:
|
112
112
|
- lib
|
@@ -121,8 +121,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
121
121
|
- !ruby/object:Gem::Version
|
122
122
|
version: '0'
|
123
123
|
requirements: []
|
124
|
-
rubygems_version: 3.
|
125
|
-
signing_key:
|
124
|
+
rubygems_version: 3.5.11
|
125
|
+
signing_key:
|
126
126
|
specification_version: 4
|
127
127
|
summary: Database-backed asynchronous priority queue system -- Extracted from Shopify
|
128
128
|
test_files:
|