feat(pull): add pull-based streams adapter - #367
Draft
tryangul wants to merge 9 commits into
Draft
Conversation
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
PullBasedAdapter— new streams adapter backed by the arroyo pull-based runtime.Depends on arroyo#559.
How
PullBasedAdapter— drop-inStreamAdapterreplacement forRustArroyoAdapter. Translates DSL steps (HeadersFilter,Batch,Map,GCSSink, etc.) into pull-based operators. Registered as"pull"inloader.py.PullConsumer— the runtime entry point. Rebuilds fresh stages on each rebalance (matching the push model's destroy/recreate pattern). Parameterlessrun()with SIGINT/SIGTERM handling.PipelineValue— type-erased payload (Raw/Rust/Python) so the adapter can compose stages dynamically from the DSL without compile-time generics for every pipeline shape.PyCallableStage— bridges Rust and Python. Wraps input in a streamsMessageobject before calling so existing callables (batch_msg_parser,ItemsSpanProcessor,serialize_to_parquet) work unchanged.GcsClient— injectable GCS upload client, separated from sink handler for testability.Why
Steel thread for the pull-based runtime — proves the arroyo primitives work end-to-end with the streams DSL and real pipeline callables (protobuf parsing, parquet serialization).
Tests (11)
Messagewrapping, realBatchParser(protobuf viasentry_kafka_schemas) +ParquetSerializer(polars) through the pipelineNotes
Mapstep.apply_concurrent()Next steps
backon)STREAM-1668