Hello all,

I got a problem in oak concerning query performance for the following simple 
queries

SELECT * FROM [rep:ACL] WHERE ISDESCENDANTNODE([/content]) 
SELECT * FROM [rep:ACL] WHERE ISDESCENDANTNODE([/var]) 

I get the following exception:

java.lang.UnsupportedOperationException: The query read or traversed more than 
150000 nodes. To avoid affecting other tasks, processing was stopped.
        at 
org.apache.jackrabbit.oak.query.FilterIterators.checkReadLimit(FilterIterators.java:66)
        at 
org.apache.jackrabbit.oak.spi.query.Cursors$TraversingCursor.fetchNext(Cursors.java:324)
        at 
org.apache.jackrabbit.oak.spi.query.Cursors$TraversingCursor.next(Cursors.java:303)
        at 
org.apache.jackrabbit.oak.query.ast.SelectorImpl.next(SelectorImpl.java:409)
        at 
org.apache.jackrabbit.oak.query.QueryImpl$RowIterator.fetchNext(QueryImpl.java:773)
        at 
org.apache.jackrabbit.oak.query.QueryImpl$RowIterator.hasNext(QueryImpl.java:798)
        at 
org.apache.jackrabbit.oak.jcr.query.QueryResultImpl$3.fetch(QueryResultImpl.java:181)
        at 
org.apache.jackrabbit.oak.jcr.query.QueryResultImpl$3.next(QueryResultImpl.java:207)
        at 
org.apache.jackrabbit.oak.jcr.query.QueryResultImpl$3.next(QueryResultImpl.java:170)
        at 
org.apache.jackrabbit.oak.jcr.delegate.SessionDelegate$SynchronizedIterator.next(SessionDelegate.java:694)
        at 
org.apache.jackrabbit.oak.jcr.query.PrefetchIterator.next(PrefetchIterator.java:97)
        at 
org.apache.jackrabbit.commons.iterator.RangeIteratorAdapter.next(RangeIteratorAdapter.java:152)
        at 
org.apache.jackrabbit.commons.iterator.RangeIteratorDecorator.next(RangeIteratorDecorator.java:92)
        at 
org.apache.jackrabbit.commons.iterator.NodeIteratorAdapter.nextNode(NodeIteratorAdapter.java:80)
        at 
biz.netcentric.cq.tools.actool.helper.QueryHelper.getNodes(QueryHelper.java:128)
        at 
biz.netcentric.cq.tools.actool.helper.QueryHelper.getRepPolicyNodes(QueryHelper.java:90)
        at 
biz.netcentric.cq.tools.actool.dumpservice.impl.DumpserviceImpl.getACLDumpBeans(DumpserviceImpl.java:399)

Of course there is an oak:index on jcr:primaryType, so I really don’t see the 
reason why this could be such a hard query to search for nodes under a path 
that are of type rep:ACL?
(If you want more background, this query is used in the netcentric AC Tool to 
make a dump of all the existing rep policy ACL nodes)

Greetings,
Roy


Reply via email to