aboutsummaryrefslogtreecommitdiffstats
path: root/activejob/lib
diff options
context:
space:
mode:
Diffstat (limited to 'activejob/lib')
-rw-r--r--activejob/lib/active_job/enqueuing.rb2
-rw-r--r--activejob/lib/active_job/exceptions.rb4
-rw-r--r--activejob/lib/active_job/test_helper.rb4
3 files changed, 5 insertions, 5 deletions
diff --git a/activejob/lib/active_job/enqueuing.rb b/activejob/lib/active_job/enqueuing.rb
index 5609d13f5f..c5ee76a69e 100644
--- a/activejob/lib/active_job/enqueuing.rb
+++ b/activejob/lib/active_job/enqueuing.rb
@@ -67,7 +67,7 @@ module ActiveJob
false
else
ActiveSupport::Deprecation.warn(
- "Rails 6.0 will return false when the enqueuing is aborted. Make sure your code doesn't depend on it" \
+ "Rails 6.1 will return false when the enqueuing is aborted. Make sure your code doesn't depend on it" \
" returning the instance of the job and set `config.active_job.return_false_on_aborted_enqueue = true`" \
" to remove the deprecations."
)
diff --git a/activejob/lib/active_job/exceptions.rb b/activejob/lib/active_job/exceptions.rb
index 9e00942a1c..35c1476368 100644
--- a/activejob/lib/active_job/exceptions.rb
+++ b/activejob/lib/active_job/exceptions.rb
@@ -54,7 +54,7 @@ module ActiveJob
self.exception_executions[exceptions.to_s] = (exception_executions[exceptions.to_s] || 0) + 1
if exception_executions[exceptions.to_s] < attempts
- retry_job wait: determine_delay(wait), queue: queue, priority: priority, error: error
+ retry_job wait: determine_delay(seconds_or_duration_or_algorithm: wait, executions: exception_executions[exceptions.to_s]), queue: queue, priority: priority, error: error
else
if block_given?
instrument :retry_stopped, error: error do
@@ -123,7 +123,7 @@ module ActiveJob
end
private
- def determine_delay(seconds_or_duration_or_algorithm)
+ def determine_delay(seconds_or_duration_or_algorithm:, executions:)
case seconds_or_duration_or_algorithm
when :exponentially_longer
(executions**4) + 2
diff --git a/activejob/lib/active_job/test_helper.rb b/activejob/lib/active_job/test_helper.rb
index e5e2b086bc..463020a332 100644
--- a/activejob/lib/active_job/test_helper.rb
+++ b/activejob/lib/active_job/test_helper.rb
@@ -353,7 +353,7 @@ module ActiveJob
#
#
# The +args+ argument also accepts a proc which will get passed the actual
- # job's arguments. Your proc needs to returns a boolean value determining if
+ # job's arguments. Your proc needs to return a boolean value determining if
# the job's arguments matches your expectation. This is useful to check only
# for a subset of arguments.
#
@@ -426,7 +426,7 @@ module ActiveJob
# end
#
# The +args+ argument also accepts a proc which will get passed the actual
- # job's arguments. Your proc needs to returns a boolean value determining if
+ # job's arguments. Your proc needs to return a boolean value determining if
# the job's arguments matches your expectation. This is useful to check only
# for a subset of arguments.
#