michaeljmarshall commented on code in PR #20478: URL: https://github.com/apache/pulsar/pull/20478#discussion_r1218445277
########## pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/NamespacesBase.java: ########## @@ -650,29 +650,18 @@ protected CompletableFuture<Void> internalGrantPermissionOnSubscriptionAsync(Str protected CompletableFuture<Void> internalRevokePermissionsOnNamespaceAsync(String role) { return validateNamespaceOperationAsync(namespaceName, NamespaceOperation.REVOKE_PERMISSION) .thenAccept(__ -> checkNotNull(role, "Role should not be null")) - .thenCompose(__ -> validatePoliciesReadOnlyAccessAsync()) - .thenCompose(__ -> updatePoliciesAsync(namespaceName, policies -> { - policies.auth_policies.getNamespaceAuthentication().remove(role); - return policies; - })); + .thenCompose(__ -> getAuthorizationService().revokePermissionAsync(namespaceName, role)); } protected CompletableFuture<Void> internalRevokePermissionsOnSubscriptionAsync(String subscriptionName, String role) { - AuthorizationService authService = pulsar().getBrokerService().getAuthorizationService(); - if (null != authService) { Review Comment: You are right, thanks for the explanation. -- 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