activejob-temporal 0.5.0 → 0.5.1

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: ebc4386d6eac6522fba437fbdbd136334a3b5c333f6f83ad90fbfbaab5664144
4
- data.tar.gz: 53cc07919979a66c013f6dd9597064cc73929ee8930a05c351774883760a1b59
3
+ metadata.gz: f88f38d49d2e111cfcbdfe5bc2f45fb4ab9f202478e8e248dda74bce56925205
4
+ data.tar.gz: a560b2d0e446dd867915298e75faabe60eb2c1f07bd0592cf7b3be4011ad07d9
5
5
  SHA512:
6
- metadata.gz: 652237c25d9342062bebd8269328f684c2cfc1d7a630cdbe0c5be9ae0a2f7d6bce0a96f48cd47de8dbad8da7a9fe5dbbf0974cfa7b92a3a646789c4e25c78873
7
- data.tar.gz: 6503e062254a40daae4d00a97fa66a312e2d57d127c2cecd13218468ec73b9eecc168f8c3f2dcdc7734fb089f4f9b0ea7b53f4369f8e11ee0934ab4e0d05a143
6
+ metadata.gz: 885994ed9a18b4b071736502f73e9cd379a212a23739eea1a1d3308b2634261f273b82070aa154504f99a757b30ba2135b05696253816dbac2a67ea02334403a
7
+ data.tar.gz: '092927525f27f3ce13f07608f098dd53b87c2daf2665d98d3d6fc11ad4f7e243cd9701edf7dfa6a14130a89097ed04408706932ab5c59f5484803fb399b477e5'
data/CHANGELOG.md CHANGED
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [0.5.1] - 2026-11-11
11
+
12
+ ### Changed
13
+ - Allow temporalio 1.7 through 1.11 (dependency constraint is now `>= 1.4.0, < 1.12`); 1.10.1 and 1.11.0 added to the SDK contract-test matrix. Note for consumers upgrading within the range: since temporalio 1.7, workers check payload sizes before sending and fail an oversized task completion retryably instead of letting the server fail it.
14
+ - Ruby baseline moves from 4.0.3 to 4.0.9 (`.ruby-version`, CI, tools, docs and the example app). `ubuntu-latest` is now Ubuntu 26.04, where `setup-ruby` has no Ruby 4.0.3 build.
15
+
10
16
  ## [0.5.0] - 2026-08-07
11
17
 
12
18
  ### Added
data/CONTRIBUTING.md CHANGED
@@ -2,17 +2,17 @@
2
2
 
3
3
  ## Ruby Baseline
4
4
 
5
- Use Ruby 4.0.3 for local development and validation. The repository targets Ruby 4+ and does not require installing Ruby 3.
5
+ Use Ruby 4.0.9 for local development and validation. The repository targets Ruby 4+ and does not require installing Ruby 3.
6
6
 
7
7
  See [Ruby Baseline](docs/ruby_baseline.md) for the source-of-truth files, CI coverage, and external tooling notes.
8
8
 
9
9
  Run validation commands through the Ruby 4 toolchain:
10
10
 
11
11
  ```sh
12
- rvm 4.0.3 do bundle install
13
- rvm 4.0.3 do bundle exec rake spec:unit
14
- rvm 4.0.3 do bundle exec rubocop
15
- rvm 4.0.3 do bundle exec rake build
12
+ rvm 4.0.9 do bundle install
13
+ rvm 4.0.9 do bundle exec rake spec:unit
14
+ rvm 4.0.9 do bundle exec rubocop
15
+ rvm 4.0.9 do bundle exec rake build
16
16
  ```
17
17
 
18
18
  ## Mutation Testing
@@ -20,7 +20,7 @@ rvm 4.0.3 do bundle exec rake build
20
20
  Mutation testing runs a scoped Mutant baseline against deterministic unit-level code:
21
21
 
22
22
  ```sh
23
- rvm 4.0.3 do bundle exec rake mutation
23
+ rvm 4.0.9 do bundle exec rake mutation
24
24
  ```
25
25
 
26
26
  The default subject list is intentionally small so the task stays fast and does not require a local Temporal server. Expand `.mutant.yml` as specs are hardened around additional code paths.
@@ -46,7 +46,7 @@ Do not add a README maintainability badge until the repository has been added to
46
46
  Generate release changelog updates from merged GitHub pull requests and closed issues:
47
47
 
48
48
  ```sh
49
- CHANGELOG_GITHUB_TOKEN=... rvm 4.0.3 do bundle exec rake changelog:generate
49
+ CHANGELOG_GITHUB_TOKEN=... rvm 4.0.9 do bundle exec rake changelog:generate
50
50
  ```
51
51
 
52
52
  The task also accepts `GITHUB_TOKEN` when `CHANGELOG_GITHUB_TOKEN` is not set. Review the generated `CHANGELOG.md` before committing release notes.
data/README.md CHANGED
@@ -172,16 +172,16 @@ See [examples/basic_rails_app](examples/basic_rails_app/) for a Docker Compose R
172
172
  Install dependencies and run the focused local checks:
173
173
 
174
174
  ```bash
175
- rvm 4.0.3 do bundle install
176
- rvm 4.0.3 do bundle exec rake spec:unit
177
- rvm 4.0.3 do bundle exec rubocop
178
- rvm 4.0.3 do bundle exec rake build
175
+ rvm 4.0.9 do bundle install
176
+ rvm 4.0.9 do bundle exec rake spec:unit
177
+ rvm 4.0.9 do bundle exec rubocop
178
+ rvm 4.0.9 do bundle exec rake build
179
179
  ```
180
180
 
181
181
  For changes near configured mutation subjects, also run:
182
182
 
183
183
  ```bash
184
- rvm 4.0.3 do bundle exec rake mutation
184
+ rvm 4.0.9 do bundle exec rake mutation
185
185
  ```
186
186
 
187
187
  Keep docs updated when behavior changes. The scoped mutation task runs on Ruby 4. Mutant 0.16 may warn about an older parser dependency; keep using the Ruby 4 toolchain and treat parser failures on new Ruby syntax as a mutation tooling limitation.
@@ -37,7 +37,7 @@ Gem::Specification.new do |spec|
37
37
  spec.add_dependency "activemodel", ">= 7.2", "< 9"
38
38
  spec.add_dependency "concurrent-ruby", "~> 1.1"
39
39
  spec.add_dependency "globalid", ">= 0.3"
40
- spec.add_dependency "temporalio", ">= 1.4.0", "< 1.7"
40
+ spec.add_dependency "temporalio", ">= 1.4.0", "< 1.12"
41
41
 
42
42
  # listen is an optional runtime dependency, required lazily only when credential_file_events is
43
43
  # enabled. Without it credentials still rotate, just on the poll interval instead of instantly.
@@ -49,7 +49,7 @@ Gem::Specification.new do |spec|
49
49
  spec.add_development_dependency "mutant-minitest", "~> 0.16"
50
50
  spec.add_development_dependency "prometheus-client", "~> 4.2"
51
51
  spec.add_development_dependency "rake", "~> 13.2"
52
- spec.add_development_dependency "rubocop", "~> 1.50"
52
+ spec.add_development_dependency "rubocop", "~> 1.92"
53
53
  spec.add_development_dependency "simplecov", "~> 0.22"
54
54
  spec.add_development_dependency "simplecov-lcov", "~> 0.9"
55
55
  spec.add_development_dependency "yard", "~> 0.9"
@@ -5,3 +5,5 @@ source "https://rubygems.org"
5
5
  gemspec path: ".."
6
6
 
7
7
  gem "temporalio", ENV.fetch("TEMPORALIO_VERSION")
8
+ # temporalio before 1.10 breaks on json 3 but does not declare it; 1.10+ requires json < 3 itself.
9
+ gem "json", "< 3"
@@ -57,7 +57,7 @@ module ActiveJob
57
57
  #
58
58
  # @see https://docs.temporal.io/activities Temporal Activities Guide
59
59
  # @see https://docs.temporal.io/retry-policies Temporal Retry Policies
60
- # rubocop:disable Metrics/ClassLength
60
+ # rubocop:disable-next Metrics/ClassLength
61
61
  class AjRunnerActivity < Temporalio::Activity::Definition
62
62
  IDEMPOTENCY_KEY = :aj_temporal_idempotency_key
63
63
  DESERIALIZATION_ERROR_CLASSES = [
@@ -504,7 +504,6 @@ module ActiveJob
504
504
  Time.zone&.name if Time.respond_to?(:zone)
505
505
  end
506
506
  end
507
- # rubocop:enable Metrics/ClassLength
508
507
  end
509
508
  end
510
509
  end
@@ -11,7 +11,7 @@ require_relative "payload_serializers"
11
11
  require_relative "rate_limit_options"
12
12
  require_relative "tls_file"
13
13
 
14
- # rubocop:disable Metrics/ModuleLength
14
+ # rubocop:disable-next Metrics/ModuleLength
15
15
  module ActiveJob
16
16
  module Temporal
17
17
  LOCALE_PATH = File.expand_path("locales/en.yml", __dir__)
@@ -656,7 +656,7 @@ module ActiveJob
656
656
  #
657
657
  # @see ActiveJob::Temporal::Configuration.validate!
658
658
  # @api private
659
- # rubocop:disable Metrics/ClassLength
659
+ # rubocop:disable-next Metrics/ClassLength
660
660
  class ConfigValidator
661
661
  include ActiveModel::Validations
662
662
 
@@ -1197,7 +1197,5 @@ module ActiveJob
1197
1197
  nil
1198
1198
  end
1199
1199
  end
1200
- # rubocop:enable Metrics/ClassLength
1201
1200
  end
1202
1201
  end
1203
- # rubocop:enable Metrics/ModuleLength
@@ -44,12 +44,11 @@ module ActiveJob
44
44
  workflow_id
45
45
  end
46
46
 
47
- # rubocop:disable Naming/PredicateMethod
47
+ # rubocop:disable-next Naming/PredicateMethod
48
48
  def discard(job_class, job_id, reason: nil, client: ActiveJob::Temporal.client)
49
49
  handle_for(job_class, job_id, client: client).signal(:discard, reason)
50
50
  true
51
51
  end
52
- # rubocop:enable Naming/PredicateMethod
53
52
 
54
53
  def workflow_id(job_class, job_id)
55
54
  class_name = job_class.is_a?(Class) ? job_class.name : job_class.to_s
@@ -11,7 +11,7 @@ require_relative "retry_mapper"
11
11
 
12
12
  module ActiveJob
13
13
  module Temporal
14
- # rubocop:disable Metrics/ClassLength
14
+ # rubocop:disable-next Metrics/ClassLength
15
15
  class JobPayloadBuilder
16
16
  include JobPayloadChildWorkflows
17
17
  include JobPayloadChainBuilder
@@ -204,6 +204,5 @@ module ActiveJob
204
204
  value
205
205
  end
206
206
  end
207
- # rubocop:enable Metrics/ClassLength
208
207
  end
209
208
  end
@@ -5,7 +5,7 @@ require_relative "../observability"
5
5
  module ActiveJob
6
6
  module Temporal
7
7
  module Observability
8
- # rubocop:disable Metrics/ClassLength
8
+ # rubocop:disable-next Metrics/ClassLength
9
9
  class Datadog < Adapter
10
10
  attr_accessor :service, :statsd_host, :statsd_port
11
11
  attr_writer :statsd
@@ -156,7 +156,6 @@ module ActiveJob
156
156
  Process.clock_gettime(Process::CLOCK_MONOTONIC)
157
157
  end
158
158
  end
159
- # rubocop:enable Metrics/ClassLength
160
159
  end
161
160
  end
162
161
  end
@@ -50,7 +50,7 @@ module ActiveJob
50
50
  end
51
51
  end
52
52
 
53
- # rubocop:disable Metrics/ClassLength
53
+ # rubocop:disable-next Metrics/ClassLength
54
54
  class Prometheus < Adapter
55
55
  DURATION_BUCKETS = [0.005, 0.01, 0.025, 0.05, 0.1, 0.25, 0.5, 1, 2.5, 5, 10, 30, 60, 120].freeze
56
56
  PAYLOAD_SIZE_BUCKETS = [512, 1024, 2_048, 4_096, 8_192, 16_384, 32_768, 65_536, 131_072, 262_144,
@@ -260,7 +260,6 @@ module ActiveJob
260
260
  (value || "unknown").to_s
261
261
  end
262
262
  end
263
- # rubocop:enable Metrics/ClassLength
264
263
  end
265
264
  end
266
265
  end
@@ -30,7 +30,7 @@ module ActiveJob
30
30
  # @example Extracting discard handlers
31
31
  # discard_handlers = extractor.discard_handlers(MyJob)
32
32
  # # => [{ exception: ActiveRecord::RecordNotFound, handler: ... }]
33
- # rubocop:disable Metrics/ClassLength
33
+ # rubocop:disable-next Metrics/ClassLength
34
34
  class RetryHandlerExtractor
35
35
  def initialize
36
36
  @cache_mutex = Mutex.new
@@ -371,6 +371,5 @@ module ActiveJob
371
371
  candidate_class <= handler_class
372
372
  end
373
373
  end
374
- # rubocop:enable Metrics/ClassLength
375
374
  end
376
375
  end
@@ -53,7 +53,7 @@ module ActiveJob
53
53
  heartbeat_timeout
54
54
  ].freeze
55
55
 
56
- # rubocop:disable Metrics/BlockLength
56
+ # rubocop:disable-next Metrics/BlockLength
57
57
  class_methods do
58
58
  # Define Temporal activity timeout options for this job class.
59
59
  #
@@ -130,7 +130,6 @@ module ActiveJob
130
130
  end
131
131
  end
132
132
  end
133
- # rubocop:enable Metrics/BlockLength
134
133
  end
135
134
  end
136
135
  end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module ActiveJob
4
4
  module Temporal
5
- VERSION = "0.5.0"
5
+ VERSION = "0.5.1"
6
6
  end
7
7
  end
@@ -6,7 +6,7 @@ require_relative "bind_policy"
6
6
 
7
7
  module ActiveJob
8
8
  module Temporal
9
- # rubocop:disable Metrics/ClassLength
9
+ # rubocop:disable-next Metrics/ClassLength
10
10
  class WorkerPool
11
11
  Child = Data.define(:pid, :index, :restarts)
12
12
 
@@ -416,6 +416,5 @@ module ActiveJob
416
416
  end
417
417
  end
418
418
  end
419
- # rubocop:enable Metrics/ClassLength
420
419
  end
421
420
  end
@@ -25,7 +25,7 @@ module ActiveJob
25
25
  # config = ActiveJob::Temporal.config
26
26
  # enqueuer = WorkflowEnqueuer.new(client, config)
27
27
  # enqueuer.enqueue(job)
28
- # rubocop:disable Metrics/ClassLength
28
+ # rubocop:disable-next Metrics/ClassLength
29
29
  class WorkflowEnqueuer
30
30
  include WorkflowEnqueuerBatch
31
31
 
@@ -267,6 +267,5 @@ module ActiveJob
267
267
  raise ArgumentError, "scheduled_at must be an ISO8601 string or respond to to_time"
268
268
  end
269
269
  end
270
- # rubocop:enable Metrics/ClassLength
271
270
  end
272
271
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: activejob-temporal
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Temporal Technologies
@@ -87,7 +87,7 @@ dependencies:
87
87
  version: 1.4.0
88
88
  - - "<"
89
89
  - !ruby/object:Gem::Version
90
- version: '1.7'
90
+ version: '1.12'
91
91
  type: :runtime
92
92
  prerelease: false
93
93
  version_requirements: !ruby/object:Gem::Requirement
@@ -97,7 +97,7 @@ dependencies:
97
97
  version: 1.4.0
98
98
  - - "<"
99
99
  - !ruby/object:Gem::Version
100
- version: '1.7'
100
+ version: '1.12'
101
101
  - !ruby/object:Gem::Dependency
102
102
  name: benchmark-ips
103
103
  requirement: !ruby/object:Gem::Requirement
@@ -222,14 +222,14 @@ dependencies:
222
222
  requirements:
223
223
  - - "~>"
224
224
  - !ruby/object:Gem::Version
225
- version: '1.50'
225
+ version: '1.92'
226
226
  type: :development
227
227
  prerelease: false
228
228
  version_requirements: !ruby/object:Gem::Requirement
229
229
  requirements:
230
230
  - - "~>"
231
231
  - !ruby/object:Gem::Version
232
- version: '1.50'
232
+ version: '1.92'
233
233
  - !ruby/object:Gem::Dependency
234
234
  name: simplecov
235
235
  requirement: !ruby/object:Gem::Requirement
@@ -413,7 +413,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
413
413
  - !ruby/object:Gem::Version
414
414
  version: '0'
415
415
  requirements: []
416
- rubygems_version: 4.0.6
416
+ rubygems_version: 4.0.20
417
417
  specification_version: 4
418
418
  summary: Rails ActiveJob adapter backed by Temporal Workflows
419
419
  test_files: []