join | multi_join | merge | split | case | cycle_link | error | whenJoin, Merge, Split, Case, and control streams
Multi-input, branching, cycle, condition, and error-flow operators.
When to use
Use these methods where graph shape, state retention, or control flow is the primary behavior.
Behavior
- Join combines exactly two KeyValue flows. MultiJoin combines one primary and one or more ordered additional KeyValue flows.
- Merge combines sources without a user callback.
- Split broadcasts; Case selects exactly one zero-based When branch.
- CycleLink closes an intentional graph cycle; Error receives failure flow.
Join methods properties
Stateful combination.
join(..., function, join_type=None, join_storage=None)StreamTwo-input keyed join. Set JoinType.INNER, LEFT, RIGHT, or OUTER and JoinStorageType.HASH_MAP before validation.
multi_join(..., function, join_storage=None)StreamVariable-input keyed join with one primary source and at least one ordered additional source. Set JoinStorageType.HASH_MAP before validation.
source / sourcesStream | Sequence[Stream]source is callback slot 0. sources are slot 1 for Join and ordered slots 1..N for MultiJoin.
ttl / renew_ttlint | bool | NoneRetention in milliseconds and renewal after an arrival when the callback returns false.
join callback resultboolTrue completes the key and clears retained values; False waits for later arrivals.
Routing methods properties
Graph branching and recombination.
merge(name, *, sources=(), appearance=None)StreamCombine multiple sources.
split(name, *, source=None, appearance=None)StreamCreate a branch point.
case(name, *, function, source=None, appearance=None)StreamBuild a selector that returns the zero-based index of exactly one attached When branch.
when(name, *, value_type=None, source=None, appearance=None)StreamRegister an ordered, typed branch on a Case. When has no Function of its own.
Control methods properties
Cycles and failures.
cycle_link(name, *, source=None, appearance=None)StreamExplicit cycle connector.
error(name, *, value_type=None, function=None, source=None, appearance=None)StreamFailure stream with optional callback.
Python example
merged = orders.merge("Merge Results")
merged << http_result << kafka_result << processing_error
split = orders.split("Split Result")
merged >> split
split >> success
split >> retry