gaurav-narula commented on code in PR #15270:
URL: https://github.com/apache/kafka/pull/15270#discussion_r1470842153
##########
server-common/src/main/java/org/apache/kafka/common/DirectoryId.java:
##########
@@ -153,6 +153,16 @@ public static boolean isOnline(Uuid dir, List<Uuid>
sortedOnlineDirs) {
if (LOST.equals(dir)) {
return false;
}
+
+ // The only time we should have a size be 0 is if we were at a MV
prior to 3.7-IV2
+ // and the system was upgraded. In this case the original list of
directories was purged
+ // during broker registration so we don't know if the directory is
online. We assume
+ // that a broker will halt if all its log directories are down.
Eventually the broker
+ // will send another registration request with information about all
log directories.
+ // Refer KAFKA-16162 for more information
+ if (sortedOnlineDirs.isEmpty()) {
+ return true;
+ }
Review Comment:
Fixed in
[29ec322](https://github.com/apache/kafka/pull/15270/commits/29ec322b21668a7227f6513d270cc3b9af3faccd)
--
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]