michaeljmarshall commented on a change in pull request #13157: URL: https://github.com/apache/pulsar/pull/13157#discussion_r770032265
########## File path: pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/NamespacesBase.java ########## @@ -1357,7 +1357,7 @@ protected void internalRemoveReplicatorDispatchRate() { } protected void internalSetReplicatorDispatchRate(DispatchRateImpl dispatchRate) { - validateSuperUserAccess(); + validateNamespacePolicyOperation(namespaceName, PolicyName.RATE, PolicyOperation.WRITE); Review comment: ```suggestion validateNamespacePolicyOperation(namespaceName, PolicyName.REPLICATION_RATE, PolicyOperation.WRITE); ``` ########## File path: pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/v1/Namespaces.java ########## @@ -122,7 +122,7 @@ @Path("/{property}/{cluster}/{namespace}/destinations") @ApiOperation(hidden = true, value = "Get the list of all the topics under a certain namespace.", response = String.class, responseContainer = "Set") - @ApiResponses(value = {@ApiResponse(code = 403, message = "Don't have admin permission"), + @ApiResponses(value = {@ApiResponse(code = 403, message = "Don't have admin or consume permission on namespace"), Review comment: @gaoran10 good point. The risk here is that custom implementations won't necessarily align with needing admin privileges. I think making it an "or" like you proposed sounds good to me. ########## File path: pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/NamespacesBase.java ########## @@ -1341,7 +1341,7 @@ protected SubscribeRate internalGetSubscribeRate() { } protected void internalRemoveReplicatorDispatchRate() { - validateSuperUserAccess(); + validateNamespacePolicyOperation(namespaceName, PolicyName.RATE, PolicyOperation.WRITE); Review comment: ```suggestion validateNamespacePolicyOperation(namespaceName, PolicyName.REPLICATION_RATE, PolicyOperation.WRITE); ``` -- 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...@pulsar.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org