kirktrue commented on code in PR #19440: URL: https://github.com/apache/kafka/pull/19440#discussion_r2051356316
########## clients/src/main/java/org/apache/kafka/clients/producer/internals/TransactionManager.java: ########## @@ -171,7 +171,25 @@ public class TransactionManager { * * See KAFKA-14831 for more detail. */ - private final ThreadLocal<Boolean> shouldPoisonStateOnInvalidTransition; + public interface InvalidTransitionAttemptPolicy { Review Comment: I've updated the approach to use a method named `shouldPoisonStateOnInvalidTransition()` which uses the default behavior (return `true` only if called from the `Sender` thread) and a subclass in `TransactionManagerTest` can optionally override that behavior, where needed. Does that seem better? -- 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: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org