chia7712 commented on code in PR #21943:
URL: https://github.com/apache/kafka/pull/21943#discussion_r3937232978


##########
core/src/main/scala/kafka/server/ControllerServer.scala:
##########
@@ -235,7 +235,7 @@ class ControllerServer(
           OptionalLong.empty()
         }
 
-        val maxIdleIntervalNs = 
config.metadataMaxIdleIntervalNs.fold(OptionalLong.empty)(OptionalLong.of)
+        val maxIdleIntervalNs = 
config.metadataMaxIdleIntervalNs.map[OptionalLong](v => 
OptionalLong.of(v)).orElse(OptionalLong.empty)

Review Comment:
   Maybe `metadataMaxIdleIntervalNs` could return `OptionalLong` instead?



##########
core/src/main/scala/kafka/server/KafkaConfig.scala:
##########
@@ -245,101 +203,6 @@ class KafkaConfig private(doLog: Boolean, val props: 
util.Map[_, _], enforceProv
     }
   }
 
-  /***************** rack configuration **************/
-  val replicaSelectorClassName = 
Option(getString(ReplicationConfigs.REPLICA_SELECTOR_CLASS_CONFIG))
-
-  /** ********* Replication configuration ***********/
-  val replicaLagTimeMaxMs = 
getLong(ReplicationConfigs.REPLICA_LAG_TIME_MAX_MS_CONFIG)

Review Comment:
   I'm wondering if those val fields should stay as fields in the Java version. 
Will evaluating them on each call be a performance regression?



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