Description
How to reproduce
Configure CompositeNodeStore with a mount test with 2 mount paths, with one path being both longer and alphabetically lower than the other (example "/x" and "/a/b").
The following code
nodeStore.getRoot().getChildNodeNames()
will then ignore the test mount and its "/x" node, because the current code only checks if the parent of the alphabetically first path (here "/a/b") is equal to the root path, which is false. However, this is incorrect as the "/x" path should have been considered.
This issue was never discovered before because the mount path configuration is always something like "/apps, /libs, /jcr:system/rep:permissionStore/oak:mount-libs-default", where "/apps", being first in alphabetic order, is always used in the check. But after OAK-9553, it will be possible to configure multiple mounts and this issue will be much more likely to happen.
Attachments
Issue Links
- links to