artemlivshits commented on code in PR #14594:
URL: https://github.com/apache/kafka/pull/14594#discussion_r1373758559


##########
core/src/main/scala/kafka/cluster/Partition.scala:
##########
@@ -1106,6 +1115,12 @@ class Partition(val topicPartition: TopicPartition,
    * @return true if the HW was incremented, and false otherwise.
    */
   private def maybeIncrementLeaderHW(leaderLog: UnifiedLog, currentTimeMs: 
Long = time.milliseconds): Boolean = {
+    if (metadataCache.isInstanceOf[KRaftMetadataCache] && 
interBrokerProtocolVersion.isElrSupported && eligibleLeaderReplicasEnabled) {

Review Comment:
   I have a higher-level question -- do we actually care if ELR is enabled for 
this logic?  It is my understanding that the logic on the brokers doesn't use 
ELR, it just has some changes that seem to improve the protocol even if ELR is 
not used / implemented:
   - strict min ISR
   - advance HWM only only if min ISR known to the controller



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to