drpc: add write queue pressure metrics#67
Merged
Conversation
shubhamdhama
force-pushed
the
shubham/receive-queue
branch
from
July 13, 2026 06:03
4a7db46 to
35a3cbe
Compare
shubhamdhama
force-pushed
the
shubham/blocked-writers
branch
2 times, most recently
from
July 13, 2026 07:20
311781e to
75a9b78
Compare
suj-krishnan
left a comment
There was a problem hiding this comment.
LGTM - we still need a histogram for avg blocked time but that is mentioned as a TODO.
shubhamdhama
force-pushed
the
shubham/receive-queue
branch
from
July 14, 2026 17:16
35a3cbe to
7ba8a1d
Compare
shubhamdhama
force-pushed
the
shubham/blocked-writers
branch
from
July 14, 2026 17:16
75a9b78 to
342b458
Compare
shubhamdhama
force-pushed
the
shubham/receive-queue
branch
from
July 15, 2026 07:19
7ba8a1d to
8ea5c1b
Compare
shubhamdhama
force-pushed
the
shubham/blocked-writers
branch
from
July 15, 2026 07:19
342b458 to
ea8e8da
Compare
shubhamdhama
force-pushed
the
shubham/receive-queue
branch
from
July 15, 2026 08:25
8ea5c1b to
69ef373
Compare
shubhamdhama
force-pushed
the
shubham/blocked-writers
branch
from
July 15, 2026 08:25
ea8e8da to
caba7e9
Compare
shubhamdhama
force-pushed
the
shubham/receive-queue
branch
from
July 15, 2026 10:32
69ef373 to
09097b0
Compare
shubhamdhama
force-pushed
the
shubham/blocked-writers
branch
from
July 15, 2026 10:32
caba7e9 to
1e7c8e2
Compare
shubhamdhama
force-pushed
the
shubham/receive-queue
branch
from
July 15, 2026 10:55
09097b0 to
43d48f0
Compare
shubhamdhama
force-pushed
the
shubham/blocked-writers
branch
from
July 15, 2026 10:55
1e7c8e2 to
ceec8a6
Compare
shubhamdhama
force-pushed
the
shubham/blocked-writers
branch
from
July 15, 2026 13:56
ceec8a6 to
8891758
Compare
DRPC combines writes from many streams in a bounded connection queue and sends batches through one transport write. Byte counters cannot show whether work is queued, writers are stalled, or a batch is stuck in Write. Add write_queue.bytes, write_queue.blocked_writers, write_queue.block_count, and write_flush.in_flight_bytes. These signals distinguish producer backpressure from a slow or stalled transport write. Keep the recording gate in ConnectionMetrics and pass that bundle directly to the writer. This makes updates visible at the state transitions that cause them and removes callback plumbing from writer options. Duration distributions remain separate histogram work.
suj-krishnan
approved these changes
Jul 16, 2026
shubhamdhama
force-pushed
the
shubham/blocked-writers
branch
from
July 16, 2026 06:23
8891758 to
c97c39d
Compare
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.
DRPC combines writes from many streams in a bounded connection queue and
sends batches through one transport write. Bytes sent cannot tell whether
work is waiting in the queue, stream writers are stalled at its limit, or a
batch is stuck in Write.
Add queue bytes, blocked writers, queue-block events, and in-flight flush
bytes to expose that pressure. These signals distinguish producer
backpressure from a slow or stalled transport write.
Keep collection policy with the connection metric bundle and give that
bundle directly to the writer. This makes queue metric updates visible at
the state transitions that cause them, removes callback plumbing from the
writer options, and applies the same recording gate across connection
metrics.
Duration distributions remain separate histogram work.