jolshan commented on code in PR #21065:
URL: https://github.com/apache/kafka/pull/21065#discussion_r2673961833
##########
clients/src/main/java/org/apache/kafka/clients/producer/internals/RecordAccumulator.java:
##########
@@ -1132,7 +1156,7 @@ void abortBatches(final RuntimeException reason) {
dq.remove(batch);
}
batch.abort(reason);
- deallocate(batch);
+ completeBatchAndDeallocate(batch);
Review Comment:
@chia7712
One thing to keep in mind is that the newer version of the transactional
protocol doesn't add the partition separately. The addition is done during the
send.
There is also a case to consider where the partitions have already been
added to the transaction and we skip straight to sending the produce request.
In either scenario though, I think this analysis is roughly the same minus
the add partitions requests (if we enter fatal state for some other reason)
--
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]