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

Aggregate logic should optimize for case where patterns do not include wildcard

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.5.18, 1.6.0
    • lucene
    • None

    Description

      Aggregate logic in oak-lucene currently tries to apply matcher on each of the child node of a modified parent node. This is required for those case where pattern involves wild card like aggregating '*/*/*' pattern.

      However this performs poorly if the aggregate does not involve pattern. For e.g. if we have defined a property definition for 'jcr:content/@status' for nt:base

        + indexRules 
         + nt:base 
          + properties 
           + status 
            - name = "jcr:content/status"
            - propertyIndex = true
      

      For above definition current logic would try to apply the matcher for 'jcr:content' on each of the child nodes. So if we have a folder have 1000 entries it would read that many child nodes.

      As a fix we should check if the aggregate path has wild card or not. if its specific then aggregate logic should directly lookup child with given name

      Attachments

        1. OAK-5448.patch
          5 kB
          Chetan Mehrotra

        Activity

          People

            chetanm Chetan Mehrotra
            chetanm Chetan Mehrotra
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: