lifepuzzlefun commented on code in PR #20512:
URL: https://github.com/apache/pulsar/pull/20512#discussion_r1225002889
##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/loadbalance/impl/ModularLoadManagerImpl.java:
##########
@@ -603,6 +602,26 @@ private void updateBundleData() {
LoadManagerShared.fillNamespaceToBundlesMap(preallocatedBundleData.keySet(),
namespaceToBundleRange);
}
}
+
+ // Remove not active bundle from loadData
+ for (String bundle : bundleData.keySet()) {
+ if (!activeBundles.contains(bundle)) {
+ long notActiveTimes = notActiveBundleCounter
+ .computeIfAbsent(bundle, k -> new
AtomicLong()).incrementAndGet();
+
+ if (notActiveTimes > nonActiveBundleDeleteThreshold) {
Review Comment:
>
In my opinion. the undelete bundle data won't harm the other logic. most
logic is just to query the bundle data. If bundle is splited. the system won't
to do ops for this bundle again.
--
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]