fix: preserve malformed Wire publication classification in Development - #452
Merged
CountableNewt merged 2 commits intoSep 15, 2026
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A malformed Wire publication currently reaches the generic retry path when PostgreSQL wraps its validation error after rollback. Preserve the known application error only after a confirmed clean rollback so the inbox records the terminal failure promptly and releases its repository's next event after that terminal transaction commits.
The classifier keeps begin, rollback, commit, and unknown database errors retryable. Cancellation is checked after cache invalidation, and the existing lease token remains authoritative. Payloads, FIFO ordering, and durable failure evidence are retained; this does not reset or delete hosted ingestion state.
Validation: the full Wire worker suite passed 372 tests with PostgreSQL, followed by the Redis-gated test separately. Four new tests cover 12 parameter cases: terminal commit/follower progress, stale lease, cancellation, recognized versus uncertain transaction errors, and real statement/commit SQL failures. The rollback-failure classifier case injects metadata into a real captured transaction wrapper. Swift 6 warnings-as-errors build and diff checks passed. A supplemental unchanged WireCore build hit local disk exhaustion; fresh required CI must pass before merge.
Roll out through the Development companion first, then verify matching worker deployments before Production promotion. No schema or configuration changes.
Fixes TSW-122.
Development already contained an earlier outer rollback unwrap and live/snapshot regression. This branch consolidates that duplicate into the cancellation-aware helper used by Production, preserving the existing Development test and other Development additions. The resulting processor is byte-identical to the tested Production patch; exact composed Development validation is required in CI.
Development validation and rollout are now superseded by composed PR454, which includes these commits with the current Development base. This PR remains an unmerged review companion until that composed rollout is verified. Its redundant CI run34918048488 was cancelled to avoid duplicate builds; Production PR451 and diagnostic PR455 remain independently gated.