codelipenghui commented on a change in pull request #13840:
URL: https://github.com/apache/pulsar/pull/13840#discussion_r787795143
##########
File path:
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/SystemTopicBasedTopicPoliciesService.java
##########
@@ -234,6 +233,7 @@ private void prepareInitPoliciesCache(NamespaceName
namespace, CompletableFuture
CompletableFuture<SystemTopicClient.Reader<PulsarEvent>>
readerCompletableFuture =
creatSystemTopicClientWithRetry(namespace);
readerCaches.put(namespace, readerCompletableFuture);
+ ownedBundlesCountPerNamespace.putIfAbsent(namespace, new
AtomicInteger(1));
Review comment:
If we move this line here, can we ensure the `ownedBundlesCount` will
decrease to 0 after all the bundles of the namespace are unloaded from this
broker?
--
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]