Preserve global arrival order of continue-as-new carryover events - #278
Merged
Bernd Verst (berndverst) merged 1 commit intoOct 1, 2026
Merged
Bernd Verst (berndverst) merged 1 commit into
Bernd Verst (berndverst) merged 1 commit into
Conversation
Track buffered event arrival indexes independently of task IDs and retain per-name FIFO consumption and raw payloads. Add replay, selective consumption, cancellation, converter, and save-events regression coverage. Fixes #277 Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
The focused fix has regression coverage for its key boundaries, and the review identified no unresolved issues.
Review effort: Balanced
Findings: None
What changed in this PR
This PR fixes the core SDK’s continue-as-new carryover order, which also affects the Azure Managed and Azure Functions providers.
Changes:
- Record buffered events’ arrival order while retaining per-name FIFO queues and raw payloads.
- Carry over only unconsumed events in arrival order, with regression coverage for replay and event-consumption cases.
- Document the user-visible fix in all three applicable changelogs.
| File | Description |
|---|---|
tests/durabletask/test_orchestration_executor.py |
Tests carryover order and payload behavior. |
durabletask/worker.py |
Tracks arrival order and sorts buffered events for carryover. |
durabletask-azuremanaged/CHANGELOG.md |
Documents the provider-visible fix. |
CHANGELOG.md |
Documents the core SDK fix. |
azure-functions-durable/CHANGELOG.md |
Documents the provider-visible fix. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Bernd Verst (berndverst)
approved these changes
Oct 1, 2026
Bernd Verst (berndverst)
left a comment
Member
There was a problem hiding this comment.
Looks good. The arrival counter preserves replay action IDs, per-name FIFO consumption, and raw payloads. The cross-name carryover ordering correction is documented across the affected packages. No public API break or new Python-version requirement.
Bernd Verst (berndverst)
deleted the
andystaples-preserve-carryover-event-arrival-order
branch
October 1, 2026 22:42
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
Fixes #277.
continue_as_new(..., save_events=True)carries unconsumed buffered events into the next execution.save_events=False. Events already delivered to live waits are not carried over.