michaeljmarshall commented on a change in pull request #14367:
URL: https://github.com/apache/pulsar/pull/14367#discussion_r809708742
##########
File path:
pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/BrokersBase.java
##########
@@ -350,12 +347,6 @@ public void healthCheck(@Suspended AsyncResponse
asyncResponse,
clientAppId(), topicName);
throw new RestException(Status.NOT_FOUND, "Topic [{}]
not found after create.");
}
- Topic topic = topicOptional.get();
- // clean all subscriptions
- return
FutureUtil.waitForAll(topic.getSubscriptions().values()
-
.stream().map(Subscription::deleteForcefully).collect(Collectors.toList()))
Review comment:
I am wondering if it is risky to remove this whole block. Instead, what
if we simply called `Subscription::delete`? That would leave any subscription
with active consumers in places. I think that should prevent the race I saw in
the issue.
Additionally, we'd need to ignore the exceptionally completed future that
the `delete` method returns.
--
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]