Skip to content

Read codec-encoded external storage references in workflow workers - #3253

Open
jmaeagle99 wants to merge 1 commit into
extstore-workflow-decode-refsfrom
extstore-workflow-decode-contexts
Open

jmaeagle99 wants to merge 1 commit into
extstore-workflow-decode-refsfrom
extstore-workflow-decode-contexts

Conversation

@jmaeagle99

Copy link
Copy Markdown
Contributor

What was changed

  • Workflow workers now decode external storage references that were encoded with the payload codec, in workflow tasks and history pages, including on replay.
  • Each reference is decoded with the serialization context its payload was written with. New internal WorkflowReferenceContexts remembers the context of each scheduled activity, Nexus operation and Nexus-sent update for as long as the run is cached, so a result in a later task or history page finds it. Entries are dropped once the server has delivered the result.
  • WorkflowRunStorage picks the codec per history event during the decode walk. User metadata, event group markers and update requests use the workflow context; a child workflow's header uses the child's namespace; a local activity marker's SDK details use the workflow context while its input and result use the local activity's context.
  • CHANGELOG: the existing unreleased "can now read" entry covers workflow workers.

Why?

Workers on this release can run workflows whose history holds encoded references, so encoding can be turned on in a later release without breaking workers that are still on this one. A context-keyed codec only decodes under the context it encoded with, so a reference decoded under the wrong context would fail the workflow task.

Checklist

  1. How was this tested:

    • new unit tests for the context table and per-event decoding
    • end-to-end test of a workflow with an activity, a Nexus operation, a query, an update and a signal across cache evictions.
  2. Any docs updates needed? No

@jmaeagle99
jmaeagle99 added this pull request to stack #3251 December 2, 2026 22:45
@jmaeagle99
jmaeagle99 requested a review from a team as a code owner December 2, 2026 22:45
@jmaeagle99
jmaeagle99 force-pushed the extstore-workflow-decode-contexts branch from 7314074 to 9bf570a Compare December 3, 2026 23:31
@jmaeagle99
jmaeagle99 force-pushed the extstore-workflow-decode-contexts branch from 9bf570a to 2289e6d Compare December 3, 2026 23:35

This branch has not been deployed

No deployments
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.

1 participant