Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix system topic replicate issue (apache#14605)
### Motivation PIP 92 has introduced topic policies across clusters. But after apache#12517, if the policy is not global, it set the replicate cluster to an empty set. ``` PulsarEvent.PulsarEventBuilder builder = PulsarEvent.builder(); if (policies == null || !policies.isGlobalPolicies()) { // we don't need to replicate local policies to remote cluster, so set `replicateTo` to empty. builder.replicateTo(new HashSet<>()); } ``` It should set the `replicateTo` with the local cluster, not an empty set. Otherwise, it will cause the system event to be replicated. Details are here : https://github.com/apache/pulsar/blob/d4c2e613d305f8f785b5ef357b7cbe2ccc271043/pulsar-broker/src/main/java/org/apache/pulsar/broker/service/persistent/PersistentReplicator.java#L319-L328
- Loading branch information