WA-RAILS7-024: ActiveJob adapter compatibility#760
Conversation
Build Gate Results
Overall: gate:build-passed — ready for Wave 1 review. |
Architecture Review{
"reviewer": "architecture",
"verdict": "PASS",
"severity": null,
"summary": "Clean, well-scoped change that stays within the configuration module boundary with no new coupling or layer violations.",
"findings": []
}Analysis: The change adds a runtime guard in
No architectural concerns. ✅ |
Security ReviewVerdict: PASS ✅ No security issues found. The change is a configuration guard that conditionally sets the ActiveJob queue adapter, with no impact on authentication, authorization, data exposure, or input handling. Production behavior is unchanged — Sidekiq remains the queue adapter for non-test environments. The guard only preserves ActiveJob's test adapter when already set, which is expected and safe. No secrets, credentials, injection surfaces, or authorization logic is affected. |
Simplicity ReviewVerdict: PASS The change is minimal and direct. The guard in is the simplest possible expression of the intent — no new abstractions, indirection layers, strategy patterns, or generalization introduced. The test is idiomatic with correct cleanup. Nothing to flag here. |
Rails Conventions ReviewVerdict: PASS_WITH_NOTES The guard logic and test structure are idiomatic. One low-priority observation: LOW — line ~79 The implementation uses Consider aligning: unless ActiveJob::Base.queue_adapter_name.to_s == 'test'
ActiveJob::Base.queue_adapter = :sidekiq
endThis is consistent with how the test already checks the adapter and uses the public Rails API rather than an internal class reference. Not a blocker. |
✅ Wave 1 Review CompleteAll Wave 1 reviewers returned PASS or PASS_WITH_NOTES.
Wave 1 gate: PASS → Proceeding to Wave 2 (rails-security, database, test-quality). |
Rails Security Review{
"reviewer": "rails-security",
"verdict": "PASS",
"severity": null,
"summary": "No security-relevant changes — diff is limited to internal ActiveJob queue adapter selection logic and a unit test; no user input handling, SQL, views, auth, secrets, or redirects.",
"findings": []
}Clean bill of health. The change guards an internal
|
Database Review{
"reviewer": "database",
"verdict": "PASS",
"severity": null,
"summary": "No database impact — this PR modifies ActiveJob queue adapter configuration only; no migrations, schema changes, queries, indexes, or association declarations are affected.",
"findings": []
}No database-relevant changes in this diff. The PR modifies |
Test Quality Review{
"reviewer": "test-quality",
"verdict": "CHANGES_REQUIRED",
"severity": "MEDIUM",
"summary": "The added test covers the guard behavior well, but issue #755 acceptance criteria (job enqueuing, retries, scheduling, unique jobs, deprecation warnings) have no test coverage in this PR or in the observed build gate run.",
"findings": [
{
"severity": "MEDIUM",
"file": "core/test/lib/workarea/configuration/sidekiq_test.rb",
"line": 1,
"issue": "Issue #755 acceptance criteria — jobs enqueue correctly, retries work, scheduled jobs work, unique jobs constraint enforced, no deprecation warnings — are not covered by any test in this PR. The build gate only ran sidekiq_test.rb, leaving it unknown whether integration-level tests for these criteria exist anywhere in the suite.",
"suggestion": "Either add integration tests covering the remaining acceptance criteria in this PR, or explicitly document (in the PR description or a follow-up issue) which ticket/test file covers each remaining criterion. Do not close #755 until all acceptance criteria have test coverage you can point to."
},
{
"severity": "LOW",
"file": "core/test/lib/workarea/configuration/sidekiq_test.rb",
"line": 1,
"issue": "The new guard introduces two branches: skip when TestAdapter, set :sidekiq otherwise. Only the skip branch is explicitly tested. The inverse path (adapter set to :sidekiq when not TestAdapter) has no new assertion confirming the guard does not accidentally suppress normal initialization.",
"suggestion": "Add a companion test: with a non-test adapter set, call configure_plugins! and assert adapter_name is 'sidekiq'. This makes both branches explicit and guards against future regressions in the guard condition."
}
]
}FindingsMEDIUM — Acceptance criteria gap (no tests for retries, scheduling, unique jobs, enqueue behavior) The fix itself is narrow and correct: the guard prevents the TestAdapter from being overridden in test environments. The new test validates that behavior cleanly, with proper isolation (ensure block restores original adapter) and a clear assertion. The gap is at the issue level. Issue #755 carries these acceptance criteria:
None of these are tested here, and the build gate only ran LOW — Only the 'skip' branch of the new guard is explicitly tested The guard adds a conditional: if TestAdapter → skip, else → set sidekiq. The added test covers the skip case. A companion test exercising the else branch would make both paths explicit and catch any future regression where the guard condition is accidentally broadened. This is minor since the else path is pre-existing behavior, but it would complete the branch coverage story for this method. |
{
"reviewer": "performance",
"verdict": "PASS",
"severity": null,
"summary": "One-time initialization guard with negligible overhead; no performance concerns.",
"findings": []
}Performance Review — PASS This change adds a single
Nothing to optimize here. The diff is already as lean as it can be. |
{
"reviewer": "frontend",
"verdict": "PASS",
"severity": null,
"summary": "No frontend files in this diff — pure server-side Ruby change.",
"findings": []
}No JavaScript, TypeScript, Stimulus, Turbo, or asset pipeline changes. This PR only modifies |
|
A11y review: PASS. This PR only changes Ruby configuration/test code (ActiveJob adapter guard + test) and does not touch any user-facing UI (views, HTML/CSS/JS). No accessibility impact detected. |
{"reviewer":"accessibility","verdict":"PASS","severity":null,"summary":"No user-facing UI changes; server-side ActiveJob adapter guard only.","findings":[]}A11y review: PASS. This PR only changes Ruby configuration/test code (ActiveJob adapter guard + test) and does not touch any user-facing UI (views, HTML/CSS/JS). No accessibility impact detected. |
Fixes #755.
Summary
configure_plugins!does not clobber:test.Why
Rails test suites (and Workarea::TestCase helpers) rely on ActiveJob's test adapter features like
perform_enqueued_jobs. Overriding the adapter to Sidekiq breaks those helpers.Client impact
None expected. Production behavior remains Sidekiq-backed; test suites retain the ActiveJob test adapter.