Aias00 commented on code in PR #10957:
URL: https://github.com/apache/rocketmq/pull/10957#discussion_r3801640880
##########
namesrv/src/main/java/org/apache/rocketmq/namesrv/NamesrvStartup.java:
##########
@@ -190,7 +195,11 @@ public static ControllerManager
createAndStartControllerManager() throws Excepti
public static ControllerManager createControllerManager() throws Exception
{
NettyServerConfig controllerNettyServerConfig = (NettyServerConfig)
nettyServerConfig.clone();
- ControllerManager controllerManager = new
ControllerManager(controllerConfig, controllerNettyServerConfig,
nettyClientConfig);
+ controllerAuthConfig.setConfigName("controller-" +
controllerConfig.getControllerDLegerSelfId());
Review Comment:
Fixed in 851ac7a62. controllerAuthConfig is now initialized eagerly, and the
parsed properties are applied to that same instance when embedded Controller is
enabled.
##########
auth/src/main/java/org/apache/rocketmq/auth/authorization/builder/DefaultAuthorizationContextBuilder.java:
##########
@@ -565,6 +568,8 @@ staticTopic, requireResource(mappingDetail.getTopic(),
"mapping topic"))) {
Resource.of(ResourceType.GROUP, null,
ResourcePattern.ANY), Action.LIST, sourceIp));
break;
case RequestCode.SET_COMMITLOG_READ_MODE:
+ case RequestCode.UPDATE_CONTROLLER_CONFIG:
Review Comment:
Confirmed intentional. CLEAN_BROKER_DATA mutates cluster-level controller
state and follows the existing cluster-wide maintenance operations
(CLEAN_EXPIRED_CONSUMEQUEUE, DELETE_EXPIRED_COMMITLOG, CLEAN_UNUSED_TOPIC),
which are all authorized with Action.UPDATE. Action.DELETE is reserved here for
concrete topic/group resource deletion.
--
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]