Skip to content

[Brook] Served the five Stream service operations through the extension. - #19

Closed
moetemp wants to merge 7 commits into
moe/brook/v3/s2-redis-storefrom
moe/brook/v3/s3-stream-service
Closed

moetemp wants to merge 7 commits into
moe/brook/v3/s2-redis-storefrom
moe/brook/v3/s3-stream-service

Conversation

@moetemp

@moetemp moetemp commented Oct 21, 2026

Copy link
Copy Markdown
Owner

What changed?

This PR adds RedisStreamExtension, the WorkerExtension that serves CreateStream, AppendRecords, CloseStream, ReadRecords and DescribeStream through call_async, by operation name and proto bytes. ReadRecords is a long poll with an inclusive from_offset, create_wait, idle_timeout and the Retention gap check. Every read ends with the close Record or an Idle Record, a read of an expired open Stream fails at once, and a Superseded item passes every Topic filter. Errors go to lang as an ExtensionError with the gRPC code and a reason token.

Why?

Activities and clients reach the Store through the bridge's generic call, so the bridge has no stream code. The extension connects on first use, so a bridge can build it with no runtime.

How did you test it?

STREAMS_REQUIRE=redis cargo test -p temporalio-streams --test service, on standalone and cluster Redis.

  • Unit Tests
  • Staging
  • End to End Tests

Activities and clients reach the Store through the bridge's generic async call, by operation name and proto bytes. A read is the long poll of the proposal, with the create wait, the idle end and the Retention check.
A Tombstone gets no more Records, so a Reader that waited on it never ended. A Topic filter with no match also scanned the whole log in one page.
@moetemp

moetemp commented Oct 25, 2026

Copy link
Copy Markdown
Owner Author

Closing as stale. This layer is folded into the v5 tip, #41, and the upstream review uses a fresh series instead. Plan: https://www.notion.so/4048fc567738814990b7c796ac28fe3f

@moetemp moetemp closed this Oct 25, 2026
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