Repository navigation
Conversation
moetemp
force-pushed
the
moe/streams-runtime-api
branch
6 times, most recently
from
November 11, 2026 17:45
b6c43fb to
4bcd0eb
Compare
A bridge calls the runtime's typed methods or their byte form, and holds each writer as an object. Each byte call decodes its request, and every call fails with Unsupported, so the API comes before the Store and the logic of the calls.
The read and describe docs of the stubs named items and the Retention, which the API removed.
moetemp
force-pushed
the
moe/streams-runtime-api
branch
from
November 12, 2026 09:51
4bcd0eb to
4c8120b
Compare
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.
What was changed
This PR adds the top-level API of the
temporalio-streamsruntime, with every call stubbed.A bridge builds one
StreamRuntimeper client. The runtime has one typed method for each call, anddispatch.rshas their byte forms for a bridge.StreamRuntime::calltakes a method name and the encoded request, and gives back the encoded response or aStreamError. So a bridge decodes no proto, and the Stream logic stays in this crate. sdk-python's bridge does this intemporalio/bridge/src/streams.rs.callCreateStreamCreateStreamRequestCreateStreamResponseAppendRecordsAppendRecordsRequestAppendRecordsResponseCloseStreamCloseStreamRequestCloseStreamResponseReadRecordsReadRecordsRequestReadRecordsResponseDescribeStreamDescribeStreamRequestDescribeStreamResponseA writer is an object that the bridge holds. Dropping it releases it, so no call names a writer by an id.
StreamRuntime::open_writer_bytesOpenWriterRequestStreamWriterStreamWriter::write_bytesWriteRecordsRequestWriteRecordsResponseStreamWriter::close_bytesCloseWriterResponsecallare the Stream service operations. The writer messages are the runtime's own, incoresdk.streams.Reason::Unsupported. A byte call decodes its request first, so a request that doesn't decode fails withReason::Invalid.StreamRuntime::newtakes aStore, which is an empty trait here.MemoryStreamRuntimebuilds a runtime for tests from aMemoryStreamConfig, which this PR adds tostreams.proto.Why?
The review of #1733 asked to see the top-level Core API that uses the messages before anything merges into a branch. The PRs on top of this one fill the stubs, from the Store trait to the writers, and none of them changes a public signature in
runtime.rs.Checklist
cargo clippyandcargo docwith warnings as errors.