Search code examples
indexingluceneaemjackrabbit-oak

AEM 6.2 OAK Indexing Behavior


As mentioned in adobe docs - OAK does not index anything by default & custom indexes need to be created when necessary.

But OOTB lucene index under /oak:index/lucene index all content text & binary by default which is 180 degree shift to above statement. If this is true than ideally same lucene index should be used for search and we should not see error.

Source - AEM Lucene OOTB Index - Q43

WARN Traversed 1000 nodes with filter Filter(query=select ...) consider creating an index or changing the query

Of course it does not index any property but still things should be good as most of times query goes for content only. Can anybody suggest?


Solution

  • As per oak docs following indexes are available OOTB and hold true for AEM repo as well. These may fulfill indexing/search needs OR may not depending upon use case as i hope aem will try to use below index defs as best as possible.

    • A property index for each indexed property.
    • A full-text index which is based on Apache Lucene / Solr.
    • A node type index (which is based on an property index for the properties cr:primaryType and jcr:mixins).
    • A traversal index that iterates over a subtree.

    Finally for any search if AEM indexing module does not find any matching index definitions as above, it will go to repo traversal warning indexing error in logs to create index. So these scenarios will always fall under custom index definition creation process.