CalvinConfluent commented on code in PR #13408:
URL: https://github.com/apache/kafka/pull/13408#discussion_r1153870001


##########
core/src/main/scala/kafka/server/AlterPartitionManager.scala:
##########
@@ -283,7 +283,7 @@ class DefaultAlterPartitionManager(
         val partitionData = new AlterPartitionRequestData.PartitionData()
           .setPartitionIndex(item.topicIdPartition.partition)
           .setLeaderEpoch(item.leaderAndIsr.leaderEpoch)
-          .setNewIsr(item.leaderAndIsr.isr.map(Integer.valueOf).asJava)
+          
.setNewIsrWithEpochs(AlterPartitionRequest.newIsrToSimpleNewIsrWithBrokerEpochs(item.leaderAndIsr.isr.map(Integer.valueOf).asJava))

Review Comment:
   I agree it is wasteful to have an intermediate collection of converting a 
scala list to a java list. I did not find a good way to modify the 
newIsrToSimpleNewIsrWithBrokerEpochs to accept a scala list of _Int_. So I just 
put 2 extra lines in this file.
   But anyway, in part 3, the newIsrToSimpleNewIsrWithBrokerEpochs will be 
replaced with real data.



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