Uploaded image for project: 'Jackrabbit Oak'
  1. Jackrabbit Oak
  2. OAK-9179

Documentation (and comments) about rep:glob patterns in ACE restriction is confusing

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Task
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.34.0
    • core, docs
    • None

    Description

      There appears to be a bit of disconnect (or at least language differences) between what the documentation says and what actually happens

      1. /cat/ and /cat/* seem to behave identically
        • FWIW, that's what documentation also seems to suggest, but the terminology is confusing [0] [1]
        • the tests [2] [3], though not exactly the same, seem imply the equivalence
        • 'descendants' implies "all", so we should either add "all" to both [0] and [1], or remove it altogether for consistency - essentially, we should use the exact same description for both the patterns if they are equivalent in all respects, or update the language to highlight/contrast the difference
      2. /cat says "the node and all its child items" [4].
        • the test [5] indicates that descendants can be accessed as well
        • For consistency, we should consider replacing child-items with 'descendants'

      [0]
      [1]
      [2]
      https://github.com/apache/jackrabbit-oak/blob/762764e0c7120557c1515c54322d6a0936ae04db/oak-core/src/test/java/org/apache/jackrabbit/oak/security/authorization/restriction/GlobPatternTest.java#L401-L402
      [3] https://github.com/apache/jackrabbit-oak/blob/762764e0c7120557c1515c54322d6a0936ae04db/oak-core/src/test/java/org/apache/jackrabbit/oak/security/authorization/restriction/GlobPatternTest.java#L231-L232
      [4]
      [5] https://github.com/apache/jackrabbit-oak/blob/762764e0c7120557c1515c54322d6a0936ae04db/oak-core/src/test/java/org/apache/jackrabbit/oak/security/authorization/restriction/GlobPatternTest.java#L383-L384

      Attachments

        1. image-2020-08-14-17-04-51-436.png
          3 kB
          Ashish Chopra
        2. image-2020-08-14-17-10-48-466.png
          3 kB
          Ashish Chopra
        3. slash-wildcard.png
          3 kB
          Ashish Chopra
        4. OAK-9179.patch
          15 kB
          Angela Schreiber
        5. OAK-9179-2.patch
          15 kB
          Angela Schreiber

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            angela Angela Schreiber
            ashishc Ashish Chopra
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment