activejob 7.0.8.7 → 7.0.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6e1046ffe4dfdee6b87642153375793425ee97343da76b3d12de01c324f7e1d3
4
- data.tar.gz: e9f621b62948290252d2ce4e0da82acf338f1979f2d4a6b43e721639e8357495
3
+ metadata.gz: be497ec8b1f22b64d821aa595f4a62e69d92d4f04bb066f8eab468e96a148d9a
4
+ data.tar.gz: 2a7b3b1d6e9246ebed53c5f853b65ec02da56f8d41bee74f8da8fb33887dbb02
5
5
  SHA512:
6
- metadata.gz: 5acd14bff9edd7111ceec82120ef9df63964c7ff9a94da8210f05881a9e35a4d21bbb11f9158149b08c2ed7d485224859cc4266274278541bf64095dcf777887
7
- data.tar.gz: 73d061c8a5eac3125ba9709d93fe9c432cdae53702180c3e9089a21a6918adbd09113fe7147f5517249914cc617f4cf97e153a54555482666d7b15b6d6c4b50d
6
+ metadata.gz: 14380a3a6c88fb7e1f3107decd71dc21c57fd242f058ada819da1825931986b404cb17ab185ea49b386a62b29cbed72a2020402e033588cab0ba216c33ead411
7
+ data.tar.gz: e57990031c726247763c650f293daabaaa95c57c361ae2c5b43db1d6ffc65a457a168b84b07d840158a16c5de5416fa09a133a51cc9c5ef986676d618123f420
data/CHANGELOG.md CHANGED
@@ -1,3 +1,15 @@
1
+ ## Rails 7.0.10 (October 28, 2025) ##
2
+
3
+ * No changes.
4
+
5
+
6
+ ## Rails 7.0.9 (October 28, 2025) ##
7
+
8
+ * Preserve the serialized timezone when deserializing `ActiveSupport::TimeWithZone` arguments.
9
+
10
+ *Joshua Young*
11
+
12
+
1
13
  ## Rails 7.0.8.7 (December 10, 2024) ##
2
14
 
3
15
  * No changes.
@@ -135,7 +135,8 @@ module ActiveJob
135
135
  # queue_as :default
136
136
  #
137
137
  # after_enqueue do |job|
138
- # $statsd.increment "enqueue-video-job.success"
138
+ # result = job.successfully_enqueued? ? "success" : "failure"
139
+ # $statsd.increment "enqueue-video-job.#{result}"
139
140
  # end
140
141
  #
141
142
  # def perform(video_id)
@@ -20,6 +20,9 @@ module ActiveJob
20
20
  # You can also pass a block that'll be invoked if the retry attempts fail for custom logic rather than letting
21
21
  # the exception bubble up. This block is yielded with the job instance as the first and the error instance as the second parameter.
22
22
  #
23
+ # `retry_on` and `discard_on` handlers are searched from bottom to top, and up the class hierarchy. The handler of the first class for
24
+ # which <tt>exception.is_a?(klass)</tt> holds true is the one invoked, if any.
25
+ #
23
26
  # ==== Options
24
27
  # * <tt>:wait</tt> - Re-enqueues the job with a delay specified either in seconds (default: 3 seconds),
25
28
  # as a computing proc that takes the number of executions so far as an argument, or as a symbol reference of
@@ -78,6 +81,9 @@ module ActiveJob
78
81
  #
79
82
  # You can also pass a block that'll be invoked. This block is yielded with the job instance as the first and the error instance as the second parameter.
80
83
  #
84
+ # `retry_on` and `discard_on` handlers are searched from bottom to top, and up the class hierarchy. The handler of the first class for
85
+ # which <tt>exception.is_a?(klass)</tt> holds true is the one invoked, if any.
86
+ #
81
87
  # ==== Example
82
88
  #
83
89
  # class SearchIndexingJob < ActiveJob::Base
@@ -9,8 +9,8 @@ module ActiveJob
9
9
  module VERSION
10
10
  MAJOR = 7
11
11
  MINOR = 0
12
- TINY = 8
13
- PRE = "7"
12
+ TINY = 10
13
+ PRE = nil
14
14
 
15
15
  STRING = [MAJOR, MINOR, TINY, PRE].compact.join(".")
16
16
  end
@@ -2,9 +2,18 @@
2
2
 
3
3
  module ActiveJob
4
4
  module Serializers
5
- class TimeWithZoneSerializer < TimeObjectSerializer # :nodoc:
5
+ class TimeWithZoneSerializer < ObjectSerializer # :nodoc:
6
+ NANO_PRECISION = 9
7
+
8
+ def serialize(time_with_zone)
9
+ super(
10
+ "value" => time_with_zone.iso8601(NANO_PRECISION),
11
+ "time_zone" => time_with_zone.time_zone.tzinfo.name
12
+ )
13
+ end
14
+
6
15
  def deserialize(hash)
7
- Time.iso8601(hash["value"]).in_time_zone
16
+ Time.iso8601(hash["value"]).in_time_zone(hash["time_zone"] || Time.zone)
8
17
  end
9
18
 
10
19
  private
@@ -54,15 +54,10 @@ module ActiveJob
54
54
  queue_adapter_changed_jobs.each { |klass| klass.disable_test_adapter }
55
55
  end
56
56
 
57
- # Specifies the queue adapter to use with all Active Job test helpers.
58
- #
59
- # Returns an instance of the queue adapter and defaults to
60
- # ActiveJob::QueueAdapters::TestAdapter.
61
- #
62
- # Note: The adapter provided by this method must provide some additional
63
- # methods from those expected of a standard ActiveJob::QueueAdapter
64
- # in order to be used with the active job test helpers. Refer to
65
- # ActiveJob::QueueAdapters::TestAdapter.
57
+ # Returns a queue adapter instance to use with all Active Job test helpers.
58
+ # By default, returns an instance of ActiveJob::QueueAdapters::TestAdapter.
59
+ # Override this method to specify a different adapter. The adapter must
60
+ # implement the same interface as ActiveJob::QueueAdapters::TestAdapter.
66
61
  def queue_adapter_for_test
67
62
  ActiveJob::QueueAdapters::TestAdapter.new
68
63
  end
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: activejob
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.0.8.7
4
+ version: 7.0.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Heinemeier Hansson
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2024-12-10 00:00:00.000000000 Z
10
+ date: 1980-01-02 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: activesupport
@@ -16,14 +15,14 @@ dependencies:
16
15
  requirements:
17
16
  - - '='
18
17
  - !ruby/object:Gem::Version
19
- version: 7.0.8.7
18
+ version: 7.0.10
20
19
  type: :runtime
21
20
  prerelease: false
22
21
  version_requirements: !ruby/object:Gem::Requirement
23
22
  requirements:
24
23
  - - '='
25
24
  - !ruby/object:Gem::Version
26
- version: 7.0.8.7
25
+ version: 7.0.10
27
26
  - !ruby/object:Gem::Dependency
28
27
  name: globalid
29
28
  requirement: !ruby/object:Gem::Requirement
@@ -100,12 +99,11 @@ licenses:
100
99
  - MIT
101
100
  metadata:
102
101
  bug_tracker_uri: https://github.com/rails/rails/issues
103
- changelog_uri: https://github.com/rails/rails/blob/v7.0.8.7/activejob/CHANGELOG.md
104
- documentation_uri: https://api.rubyonrails.org/v7.0.8.7/
102
+ changelog_uri: https://github.com/rails/rails/blob/v7.0.10/activejob/CHANGELOG.md
103
+ documentation_uri: https://api.rubyonrails.org/v7.0.10/
105
104
  mailing_list_uri: https://discuss.rubyonrails.org/c/rubyonrails-talk
106
- source_code_uri: https://github.com/rails/rails/tree/v7.0.8.7/activejob
105
+ source_code_uri: https://github.com/rails/rails/tree/v7.0.10/activejob
107
106
  rubygems_mfa_required: 'true'
108
- post_install_message:
109
107
  rdoc_options: []
110
108
  require_paths:
111
109
  - lib
@@ -120,8 +118,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
120
118
  - !ruby/object:Gem::Version
121
119
  version: '0'
122
120
  requirements: []
123
- rubygems_version: 3.5.22
124
- signing_key:
121
+ rubygems_version: 3.6.9
125
122
  specification_version: 4
126
123
  summary: Job framework with pluggable queues.
127
124
  test_files: []