Expand my Community achievements bar.

AEM 6.2 OAK Indexing

Avatar

Level 2

We have below SQL type traversal query in our application-

select * from nt:base where jcr:path like '/content/xyz/en_US/vehicles/%' and id='ABCD' and personal='true' and isUS='true';

 

We have added oak:index for the properties like id, personal, isUS(as mentioned in query above).But it still goes on traversing full directory and page crashes or times out. It shows the error like these in log files.

.query.Cursors$TraversingCursor Traversed 100000 nodes with filter Filter(query=select * from nt:base where jcr:path like '/content/xyz/en_US/vehicles/%' and id='ABCD' and personal='true' and isUS='true', path=*, property=[personal=[true], isUS=[true], id=[ABCD]]); consider creating an index or changing the query

Please advice on possible resolution.

3 Replies

Avatar

Level 10

It seems that the OAK INdex is not properly set. Have you watched this GEMS session on this subject: 

https://docs.adobe.com/ddc/en/gems/oak-lucene-indexes.html

Avatar

Employee Advisor

Can you post your index definition?

Jörg

Avatar

Level 9

@Mandeep,

ACS Commons explain query tool can help you whether index is being applied or not. And, it would be great if you can provide index details. Is it property index for each property or something else?

for more details

https://adobe-consulting-services.github.io/acs-aem-tools/explain-query.html

Regards,

Jitendra