jolshan commented on code in PR #15486: URL: https://github.com/apache/kafka/pull/15486#discussion_r1521977816
########## core/src/main/scala/kafka/server/AddPartitionsToTxnManager.scala: ########## @@ -42,6 +42,11 @@ object AddPartitionsToTxnManager { val VerificationTimeMsMetricName = "VerificationTimeMs" } +object OperationExpected extends Enumeration { + type operation = Value + val defaultOperation, latestProduceVersion, addPartitionWithoutVerification = Value Review Comment: I also think in scala we typically use sealed traits and case objects. See https://github.com/apache/kafka/blob/58ddd693e69599b177d09c2e384f31e7f5e11171/core/src/main/scala/kafka/controller/KafkaController.scala#L59 -- 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