cmccabe commented on code in PR #14628:
URL: https://github.com/apache/kafka/pull/14628#discussion_r1373820141


##########
core/src/main/scala/kafka/server/KafkaServer.scala:
##########
@@ -228,23 +226,26 @@ class KafkaServer(
         info(s"Cluster ID = $clusterId")
 
         /* load metadata */
-        val (preloadedBrokerMetadataCheckpoint, initialOfflineDirs) =
-          
BrokerMetadataCheckpoint.getBrokerMetadataAndOfflineDirs(config.logDirs, 
ignoreMissing = true, kraftMode = false)
-
-        if (preloadedBrokerMetadataCheckpoint.version != 0) {
-          throw new RuntimeException(s"Found unexpected version in loaded 
`meta.properties`: " +
-            s"$preloadedBrokerMetadataCheckpoint. Zk-based brokers only 
support version 0 " +
-            "(which is implicit when the `version` field is missing).")
+        val initialMetaPropsEnsemble = {
+          val loader = new MetaPropertiesEnsemble.Loader()
+          config.logDirs.foreach(loader.addLogDir(_))
+          loader.load()
         }

Review Comment:
   yes. good catch. @pprovenzano also found this bug through testing :)



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