Jackie-Jiang opened a new pull request, #19268:
URL: https://github.com/apache/pinot/pull/19268
## Summary
`MailboxServiceTest.testRemoteBufferFull` gives the sending mailbox a 1s
gRPC deadline that has to cover stream open + delivery of the first
`DEFAULT_MAX_PENDING_BLOCKS` data blocks before the remainder is spent on the
buffer-full timeout under test. Under load (e.g. CI parallel surefire forks
running the gRPC backpressure stress tests concurrently), delivery can outlive
the budget: the deadline cancels the stream after only `k < 5` data blocks, the
reader gets `k + 1` callbacks instead of the expected 6, and the test burns the
full 10s latch wait before failing:
```
java.lang.AssertionError: Timed out waiting for mailbox to receive expected
[true] but found [false]
at
org.apache.pinot.query.mailbox.MailboxServiceTest.testRemoteBufferFull(MailboxServiceTest.java:567)
```
Changes:
- Extend the deadline from 1s to 5s. The receiver-side offer timeout is
`Context.getDeadline().timeRemaining()`, so the test's wall time is roughly the
deadline — the value balances delivery headroom under load against test run
time (a comment documents this so it doesn't get tuned back down).
- Wait until the receiver buffer is actually full before sending the block
that overflows it. This makes the error path deterministic — with the
overflowing block parked in `offerData`, its `TimeoutException` always wins
over the deadline cancellation (the cancel notification is serialized behind
the parked `onNext` on the same gRPC executor), so the error block is
guaranteed to come from the buffer-full timeout rather than from the stream
cancel. It also turns a too-slow delivery into a fast, clear `Failed to deliver
mails` failure instead of an opaque latch timeout.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]