codelipenghui commented on a change in pull request #12590:
URL: https://github.com/apache/pulsar/pull/12590#discussion_r743615786



##########
File path: 
pulsar-broker-common/src/main/java/org/apache/pulsar/broker/resources/NamespaceResources.java
##########
@@ -122,7 +118,7 @@ public void setPolicies(NamespaceName ns, 
Function<Policies, Policies> function)
     }
 
     public static boolean pathIsFromNamespace(String path) {
-        return path.startsWith(BASE_POLICIES_PATH);
+        return path.startsWith(BASE_POLICIES_PATH) && 
path.substring(BASE_POLICIES_PATH.length() + 1).contains("/");

Review comment:
       We may receive a notification from the metastore 
`/admin/policies/public`,  not a complete namespace path




-- 
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]


Reply via email to