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

UserInitializer#initialize runs a query without any indexes

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 0.20
    • 1.0
    • core, security
    • None

    Description

      UserInitializer#initialize runs a UUID query at repository startup but it's not using any defined IndexProviders, which means it will traverse the entire repo [0].

      The traversal warning can also be seen running the bench tests.

      org.apache.jackrabbit.oak.spi.query.Cursors$TraversingCursor.fetchNext(Cursors.java:314)
      	at org.apache.jackrabbit.oak.spi.query.Cursors$TraversingCursor.next(Cursors.java:291)
      	at org.apache.jackrabbit.oak.query.ast.SelectorImpl.next(SelectorImpl.java:390)
      	at org.apache.jackrabbit.oak.query.QueryImpl$RowIterator.fetchNext(QueryImpl.java:627)
      	at org.apache.jackrabbit.oak.query.QueryImpl$RowIterator.hasNext(QueryImpl.java:647)
      	at org.apache.jackrabbit.oak.plugins.identifier.IdentifierManager.resolveUUID(IdentifierManager.java:317)
      	at org.apache.jackrabbit.oak.plugins.identifier.IdentifierManager.resolveUUID(IdentifierManager.java:306)
      	at org.apache.jackrabbit.oak.plugins.identifier.IdentifierManager.resolveUUID(IdentifierManager.java:302)
      	at org.apache.jackrabbit.oak.plugins.identifier.IdentifierManager.getTree(IdentifierManager.java:132)
      	at org.apache.jackrabbit.oak.security.user.AuthorizableBaseProvider.getByContentID(AuthorizableBaseProvider.java:56)
      	at org.apache.jackrabbit.oak.security.user.AuthorizableBaseProvider.getByID(AuthorizableBaseProvider.java:51)
      	at org.apache.jackrabbit.oak.security.user.UserProvider.getAuthorizable(UserProvider.java:191)
      	at org.apache.jackrabbit.oak.security.user.UserManagerImpl.getAuthorizable(UserManagerImpl.java:103)
      	at org.apache.jackrabbit.oak.security.user.UserInitializer.initialize(UserInitializer.java:116)
      	at org.apache.jackrabbit.oak.spi.lifecycle.OakInitializer.initialize(OakInitializer.java:57)
      	at org.apache.jackrabbit.oak.Oak.createContentRepository(Oak.java:534)
      	at org.apache.jackrabbit.oak.jcr.Jcr.createRepository(Jcr.java:187)
      

      Attachments

        1. OAK-1734.patch
          10 kB
          Alex Deparvu
        2. 0001-OAK-1734-UserInitializer-initialize-runs-a-query-wit.patch
          2 kB
          Jukka Zitting

        Activity

          People

            stillalex Alex Deparvu
            stillalex Alex Deparvu
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: