-
Notifications
You must be signed in to change notification settings - Fork 0
Document stream rate limiting, keepalive, and max duration expectations #11
Copy link
Copy link
Open
Labels
area/protoProto definitions, message design, or wire compatibility work.Proto definitions, message design, or wire compatibility work.good first issueSmall, well-scoped tasks for new contributors.Small, well-scoped tasks for new contributors.help wantedLooking for community contributions.Looking for community contributions.kind/docsDocumentation, examples, or community health updates.Documentation, examples, or community health updates.priority/mediumNormal priority item.Normal priority item.
Metadata
Metadata
Assignees
Labels
area/protoProto definitions, message design, or wire compatibility work.Proto definitions, message design, or wire compatibility work.good first issueSmall, well-scoped tasks for new contributors.Small, well-scoped tasks for new contributors.help wantedLooking for community contributions.Looking for community contributions.kind/docsDocumentation, examples, or community health updates.Documentation, examples, or community health updates.priority/mediumNormal priority item.Normal priority item.
Problem statement
All four bidirectional streaming RPCs (
Data,Control,HubPush,Process) have no contract-level guidance on flow control enforcement, maximum stream duration, keepalive intervals, or message rate limiting. WhileFlowControlmessages exist for backpressure, their use is optional and the protocol allows indefinite streams with no idle detection.Without documented expectations, implementations may:
FlowControlsignals (backpressure failure)Proposed change
Add stream lifecycle documentation to proto comments on each service:
Consider adding a
StreamConfigmessage for machine-readable hints:Affected area
Compatibility / migration
Comment-only changes have no wire impact. Adding
StreamConfigas an optional message is additive and backwards-compatible.Additional context
Identified during security review. The attack scenario is an attacker opening thousands of
Processstreams with minimal traffic to exhaust hub connection/goroutine limits while legitimate clients are rejected.