Make transaction sequence allocation restart-safe - #1193
Merged
greatest0fallt1me merged 1 commit intoAug 29, 2026
Conversation
|
@Emelie-Dev Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
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.
Summary
This PR makes transaction sequence allocation restart-safe.
The implementation ensures that transaction sequences remain consistent across retries, concurrent requests, process restarts, timeouts, and partial failures, preventing duplicate sequences, conflicting state, and unrecoverable transaction state.
Changes
Correctness & Recovery
The sequence allocation flow now guarantees that a retry or duplicate submission cannot produce conflicting transaction state or duplicate side effects.
Sequence state is persisted in a way that allows the operation to recover correctly after a process restart or partial failure, rather than relying on in-memory state that can be lost when the application stops.
Concurrent workers are also prevented from allocating conflicting sequences through the existing persistence guarantees.
Tests
Focused regression coverage was added for:
Validation
The repository's applicable formatting, lint, build, and test commands were run.
Any unrelated pre-existing failures are reported separately and are not introduced by this change.
Related Issue
Closes #1186