rondagostino commented on a change in pull request #10013: URL: https://github.com/apache/kafka/pull/10013#discussion_r567962340
########## File path: core/src/main/scala/kafka/coordinator/transaction/TransactionCoordinator.scala ########## @@ -30,6 +30,13 @@ import org.apache.kafka.common.record.RecordBatch import org.apache.kafka.common.requests.TransactionResult import org.apache.kafka.common.utils.{LogContext, ProducerIdAndEpoch, Time} +class TransactionStateTopicPartitionCountViaZooKeeper(zkClient: KafkaZkClient, Review comment: The logic to create a function `() => zkClient.getTopicPartitionCount(Topic.TRANSACTION_STATE_TOPIC_NAME).getOrElse(defaultValue)` is needed in 2 separate places (once in `TransactionCoordinator` and once in `TransactionStateManager`), so based on that I refactored it out into a common place here. I can remove this class if you prefer. ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org