Skip to content

Fix ordinary Worker stream authoring and prepare Rust 2.1.5 - #60

Merged
rmcdaniel merged 1 commit into
mainfrom
fix/stream-task-identity
Oct 3, 2026
Merged

rmcdaniel merged 1 commit into
mainfrom
fix/stream-task-identity

Conversation

@rmcdaniel

Copy link
Copy Markdown
Member

Customer outcome

The ordinary Rust Worker can append and close Workflow Streams against the published Server. A nonempty explicit workflow command ID wins. Otherwise it uses the durable nonempty task ID, matching the PHP/Python worker behavior. Missing both identities still fails closed. Recorded SideEffect history consumes the output on replay, including replay by a replacement task with a different ID.

Tracks #59. Server 297 remains open until the replacement published Rust crate completes the affected consumer qualification.

Changes

  • Correct the real Worker executor's stream identity selection.
  • Add a Worker regression covering absent/empty command ID, explicit precedence, changed-task replay and absent identity.
  • Add an immutable ordinary-task stream corpus fixture and actual cold Worker wire test. The old no-identity fixture now removes both possible identities.
  • Prepare compatible Rust 2.1.5 with unchanged MSRV 1.86, protocol 1.19 and public signatures. Update the version-specific release test and changelog.

Evidence

The new Worker regression fails on main with MissingWorkflowCommandIdentity before the correction. Rust 1.86 local cargo test --all-targets --all-features passes after it: 227 library tests, 12 replay corpus tests and all other targets, with no ignored tests. The actual published 2.1.4 failure, PHP/Python successful cases, sources, commands, raw histories and red result are retained in the three-part evidence archive. Its actual GitHub readback is verified byte for byte and all archived file checksums match.

PR quality and immutable-corpus gates remain required. After merge, publish immutable crate 2.1.5, rebuild the same fixture from registries and execute all three published SDK workers against Server 2.4.39 index sha256:3f07e97c95bfb0ba74070af9d167c47fd163fb648fcd51d12801f3d56517e9bc. Check accepted final append/close and genuinely late refused output before closing either owning issue.

This patch is separate from the approved Rust 3.0 cancellation candidate. It changes no persisted history format or Server contract. Existing accepted histories remain replayable and rollback to the previous binary restores the prior failure on fresh ordinary stream tasks.

@rmcdaniel rmcdaniel left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed exact head deaa9c9.

The production change is confined to the Worker stream identity selection and its diagnostic. Nonempty explicit command identity keeps precedence. The fallback uses the Server's durable task ID and refuses an empty task ID. PHP and Python already use this identity rule. Recorded effects are consumed before identity-dependent emission, so a replacement task with a different ID replays accepted output without another append.

The regression exercises the Worker executor rather than manually assigning its private state. The wire corpus additionally executes actual cold Workers, checks identical output identities on redelivery and retains failure when neither identity exists. The new immutable fixture does not change historical corpus evidence. Source version 2.1.5, product metadata, changelog and version-specific release tests agree. Public signatures, MSRV 1.86 and protocol 1.19 are unchanged.

Local Rust 1.86 all-target/all-feature tests pass. PR CI requires both Rust versions, official Avro compatibility, package/fresh consumer, documentation, immutable corpus and the aggregate target-branch gate. All must be green before merge. After merge the exact crate is published and its real Worker reruns the Server 2.4.39 stream scenario before customer-outcome closure.

The previous binary can be restored without history migration. It will retain its ordinary stream authoring failure on fresh tasks, so forward installation of this compatible patch is the useful recovery. Candidate cancellation code remains excluded.

@rmcdaniel
rmcdaniel marked this pull request as ready for review October 3, 2026 06:51
@rmcdaniel
rmcdaniel merged commit bd319b2 into main Oct 3, 2026
9 checks passed
@rmcdaniel
rmcdaniel deleted the fix/stream-task-identity branch October 3, 2026 06:51
@rmcdaniel

Copy link
Copy Markdown
Member Author

All required CI gates passed at deaa9c9 in https://github.com/durable-workflow/sdk-rust/actions/runs/37104232068, including the aggregate target-branch gate and all 10 release-entrypoint contract tests. PR merged as bd319b2 and its remote branch was removed. Immutable 2.1.5 publication and actual published stream consumer verification are the remaining gates on issue 59. The local release-test attempts were runner-blocked by missing test-tool dependencies, and are not used as qualification authority.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants