RongtongJin commented on code in PR #7661:
URL: https://github.com/apache/rocketmq/pull/7661#discussion_r1427656894


##########
namesrv/src/main/java/org/apache/rocketmq/namesrv/routeinfo/RouteInfoManager.java:
##########
@@ -307,8 +308,11 @@ public RegisterBrokerResult registerBroker(
                             entry.getValue().getTopicName())) {
                             final TopicConfig topicConfig = entry.getValue();
                             if (isPrimeSlave) {
-                                // Wipe write perm for prime slave
-                                topicConfig.setPerm(topicConfig.getPerm() & 
(~PermName.PERM_WRITE));
+                                // In Slave Acting Master mode, Namesrv will 
regard the surviving Slave with the smallest brokerId as the "agent" Master, 
and modify the brokerPermission to read-only.
+                                if (brokerData.isEnableActingMaster()){

Review Comment:
   这两个if可以放在一起



-- 
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: commits-unsubscr...@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to