ciaocloud commented on a change in pull request #13195:
URL: https://github.com/apache/pulsar/pull/13195#discussion_r765519388
##########
File path:
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/persistent/PersistentTopic.java
##########
@@ -2485,6 +2493,13 @@ private boolean shouldTopicBeRetained() {
//If the topic-level policy already exists, the namespace-level policy
cannot override the topic-level policy.
Optional<TopicPolicies> topicPolicies = getTopicPolicies();
+ if (data.topicLifecycle != null) {
Review comment:
We can definitely refactor it into the
`updateTopicPolicyByNamespacePolicy` method in `AbstractTopic`, but as that
method would be used by both `PersistentTopic` and `NonPersistentTopic`, not
sure it is the right thing to do for the non-persistent one to update
`inactiveTopicPolices` with `topicLifecycle` info. will need to double-check.
--
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]