m1a2st commented on code in PR #17440:
URL: https://github.com/apache/kafka/pull/17440#discussion_r1874197149
##########
clients/src/main/java/org/apache/kafka/clients/consumer/internals/NetworkClientDelegate.java:
##########
@@ -150,7 +155,11 @@ private void maybePropagateMetadataError() {
try {
metadata.maybeThrowAnyException();
Review Comment:
My observation is that when we encounter a metadata error, the application
thread does not immediately execute a new event, so the background thread
continues to execute `runOnce`. During the next execution of `runOnce`, the
metadata error gets cleared, resulting in the event not being propagated.
As for the event, when it throws a `TopicAuthorizationException`, it is
already considered complete by `completeExceptionally`, so this event is not
counted among the uncompleted ones. Make sense?
--
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]