Overview
Dynamically adjust replication routing topology based on back-pressure from egress network limits, switching to fan-out only when needed.
Design
Under normal conditions, each node replicates directly to all subscribers (lowest latency). When egress limits are hit:
- Back-pressure detected in outgoing replication threads → reported to main thread
- Main thread identifies which outgoing connections are back-pressured
- Signals a child thread to suspend subscription for the highest-latency remote node
- Child thread sends subscription suspension request; keeps connection open
- Remote node redirects that subscriber to another node (re-subscribes indirectly)
- Main thread monitors: resumes direct subscriptions when back-pressure clears
Key constraint
Harper doesn't proactively push replication — nodes subscribe to receive it. Back-pressure detection must bridge the gap between the sending thread (which sees network limits) and the main thread (which manages topology).
🤖 Filed by Claude on behalf of Kris.
Overview
Dynamically adjust replication routing topology based on back-pressure from egress network limits, switching to fan-out only when needed.
Design
Under normal conditions, each node replicates directly to all subscribers (lowest latency). When egress limits are hit:
Key constraint
Harper doesn't proactively push replication — nodes subscribe to receive it. Back-pressure detection must bridge the gap between the sending thread (which sees network limits) and the main thread (which manages topology).
🤖 Filed by Claude on behalf of Kris.