You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit b65c8da
Browse filesBrowse the repository at this point in the historyBrowse files
Summary:
FIFO queues data for later EventBase callbacks, but it ignores downstream `Backpressure`. It never registers for write-ready and never reports the pressure upstream. It also records fragments after the downstream call, so an inline batch completion could run before its tracker entry existed.
This diff makes FIFO handle `Backpressure` like the current SRPT handler and yielding SRPT. FIFO keeps sending in its normal callbacks and limits, registers for write-ready, and reports `Backpressure` upstream until write-ready. Pass-through frames follow the same rule.
When the socket drains, the pipeline wakes each handler that got `Backpressure` once, in the order they got it. So a handler above FIFO can wake first, while FIFO is still blocked. After this diff, FIFO asks for one more round when it unblocks, so that handler can send. It asks only if it answered `Backpressure` itself, for a write that the socket took or that FIFO queued. A writer that the socket blocked waits for the next drain. So a full socket gets one round per drain.
Like yielding SRPT, FIFO now records each fragment before the downstream call. It removes that record if the write returns `Error`. The benchmark handlers remain disconnected from production pipelines. Graceful shutdown is unchanged.
Reviewed By: robertroeser
Differential Revision: D124885417
fbshipit-source-id: 51395eea2fab4f6513eaa4c8226cc00ffd80bdc7
0 commit comments