Skip to content

Added the temporalio.streams interface types. - #27

Open
moedash wants to merge 3 commits into
moe/AI-198-if-py-1-envelope-pinfrom
moe/AI-198-if-py-2-streams-package
Open

moedash wants to merge 3 commits into
moe/AI-198-if-py-1-envelope-pinfrom
moe/AI-198-if-py-2-streams-package

Conversation

@moedash

@moedash moedash commented Oct 3, 2026

Copy link
Copy Markdown
Owner

This PR adds temporalio.streams, the stream interface every provider and every context shares, with no provider yet.

What changed?

  • temporalio.streams: StreamRecord over the temporal.api.stream.v1 envelope the previous PR brought in, typed topics, cursors with BEGINNING and END, the StreamError family, the provider protocols, StreamRef, and the body helpers that run a record's body through the data converter.
  • ProviderPlugin, plus stream_provider on client, worker and replayer config. A provider is registered once and every context finds it there.
  • Unit tests for the types.

Part of AI-198 (epic AI-37).

Why?

Workflow code, activities and clients should read and write a stream the same way, whatever store sits behind it. The interface is that contract. Landing it alone lets reviewers judge the shape before any provider or runtime code depends on it. The memory provider and the conformance suite follow in the next PR.

How did you test it?

Link to a test plan if any -

  • Unit Tests
  • Staging
  • End to End Tests

poe lint is clean. The type tests cover wire round trips, supersession, topic keys, cursors, body encoding and refs, and they pass. The client, worker, replayer and plugin suites still pass with the new config key.

One record, topic, cursor, error family and provider protocol set that every provider and every context shares.
A provider is registered once as a plugin and the contexts that ask for a stream find it in their config.
Wire round trips, supersession, topic keys, cursors, body encoding and refs, with no provider involved.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip-changelog Changelog entry rides another PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant