mattisonchao commented on code in PR #20613:
URL: https://github.com/apache/pulsar/pull/20613#discussion_r1241076829
##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/SystemTopicBasedTopicPoliciesService.java:
##########
@@ -362,13 +362,20 @@ private void
initPolicesCache(SystemTopicClient.Reader<PulsarEvent> reader, Comp
policyCacheInitMap.computeIfPresent(
reader.getSystemTopic().getTopicName().getNamespaceObject(), (k, v) -> true);
// replay policy message
- policiesCache.forEach(((topicName, topicPolicies) -> {
- if (listeners.get(topicName) != null) {
- for (TopicPolicyListener<TopicPolicies> listener :
listeners.get(topicName)) {
- listener.onUpdate(topicPolicies);
+ try {
+ policiesCache.forEach(((topicName, topicPolicies) -> {
+ if (listeners.get(topicName) != null) {
+ for (TopicPolicyListener<TopicPolicies> listener :
listeners.get(topicName)) {
+ listener.onUpdate(topicPolicies);
Review Comment:
If the listener throws an exception, it should be a bug. Do you have any
ability to auto-fix it by retry?
--
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]