muralibasani commented on code in PR #23547:
URL: https://github.com/apache/kafka/pull/23547#discussion_r4097249986
##########
clients/src/main/java/org/apache/kafka/clients/producer/internals/TransactionManager.java:
##########
@@ -965,8 +965,16 @@ synchronized void retry(TxnRequestHandler request) {
}
synchronized void authenticationFailed(AuthenticationException e) {
+ // An idempotent producer only sends InitProducerId, which is left
pending so that it is retried
+ // once the connection recovers or against another node. This matches
the produce path, where an
+ // authentication failure only fails the affected batches.
+ if (!isTransactional() || pendingRequests.isEmpty())
+ return;
+
for (TxnRequestHandler request : pendingRequests)
- request.fatalError(e);
+ request.fail(e);
Review Comment:
now that txn request is failing, a test would be better ? and with multiple
pending requests ?
--
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]