lianetm commented on code in PR #16156:
URL: https://github.com/apache/kafka/pull/16156#discussion_r1624801663
##########
clients/src/main/java/org/apache/kafka/clients/consumer/internals/ConsumerNetworkThread.java:
##########
@@ -293,12 +293,10 @@ private void closeInternal(final Duration timeout) {
* Check the unsent queue one last time and poll until all requests are
sent or the timer runs out.
*/
private void sendUnsentRequests(final Timer timer) {
- if (networkClientDelegate.unsentRequests().isEmpty())
- return;
- do {
+ while (timer.notExpired() &&
networkClientDelegate.hasAnyPendingRequests()) {
Review Comment:
sorry a bit late but one concern: wouldn't this change make that requests
that are issue with timeout 0 won't be sent out??? My understanding is that the
expected behaviour for requests with timeout 0 is fire-and-forget, so we want
to send them at least once.
--
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]