dajac commented on code in PR #15176:
URL: https://github.com/apache/kafka/pull/15176#discussion_r1454771868


##########
core/src/main/scala/kafka/server/ReplicaManager.scala:
##########
@@ -1090,38 +1090,29 @@ class ReplicaManager(val config: KafkaConfig,
    * @param producerId      the producer id for the producer writing to the 
transaction
    * @param producerEpoch   the epoch of the producer writing to the 
transaction
    * @param baseSequence    the base sequence of the first record in the batch 
we are trying to append
-   * @param requestLocal    container for the stateful instances scoped to 
this request -- this must correspond to the
-   *                        thread calling this method
    * @param callback        the method to execute once the verification is 
either completed or returns an error
    *
    * When the verification returns, the callback will be supplied the error if 
it exists or Errors.NONE.
    * If the verification guard exists, it will also be supplied. Otherwise the 
SENTINEL verification guard will be returned.
-   * This guard can not be used for verification and any appends that attenpt 
to use it will fail.
+   * This guard can not be used for verification and any appends that attempt 
to use it will fail.
    */
   def maybeStartTransactionVerificationForPartition(
     topicPartition: TopicPartition,
     transactionalId: String,
     producerId: Long,
     producerEpoch: Short,
     baseSequence: Int,
-    requestLocal: RequestLocal,
-    callback: (Errors, RequestLocal, VerificationGuard) => Unit
+    callback: Either[Errors, VerificationGuard] => Unit
   ): Unit = {
-    def generalizedCallback(preAppendErrors: Map[TopicPartition, Errors],
-                            newRequestLocal: RequestLocal,
-                            verificationGuards: Map[TopicPartition, 
VerificationGuard]): Unit = {
-      callback(
-        preAppendErrors.getOrElse(topicPartition, Errors.NONE),
-        newRequestLocal,
-        verificationGuards.getOrElse(topicPartition, 
VerificationGuard.SENTINEL))
+    def generalizedCallback(results: Map[TopicPartition, Either[Errors, 
VerificationGuard]]): Unit = {

Review Comment:
   Ack. I will take a look at https://github.com/apache/kafka/pull/15087.



-- 
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

Reply via email to