Jason918 commented on a change in pull request #12663:
URL: https://github.com/apache/pulsar/pull/12663#discussion_r745257972
##########
File path:
pulsar-metadata/src/test/java/org/apache/pulsar/metadata/LocalMemoryMetadataStoreTest.java
##########
@@ -92,4 +75,15 @@ public void testSharedInstance() throws Exception {
assertFalse(store1.exists("/test").join());
});
}
+
+ @Test
+ public void testPathValid() {
+ assertFalse(AbstractMetadataStore.isValidPath(null));
+ assertFalse(AbstractMetadataStore.isValidPath(""));
+ assertFalse(AbstractMetadataStore.isValidPath(" "));
+ assertFalse(AbstractMetadataStore.isValidPath("/"));
Review comment:
It's intentional false in previous code.
I think it's because all valid path comes with some prefix like
"/admin/xxx", and the root node is not used.
--
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]