[
https://issues.apache.org/jira/browse/OAK-985?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13760161#comment-13760161
]
Alex Parvulescu edited comment on OAK-985 at 9/6/13 12:15 PM:
--------------------------------------------------------------
more to the point, there's another problem that affect the query run duration
here, if the filter doesn't contain the proper node type info, the query engine
will not be able to pick up the node type index, and it will usually fall back
to traversal, which can be quite a punch.
this can be seen for a simple query (no contains clause) like:
//*[(@jcr:primaryType='nt:file')]
[~tmueller] maybe you could take a look.
was (Author: alex.parvulescu):
more to the point, there's another problem that affect the query run
duration here, if the filter doesn't contain the proper node type info, the
query engine will not be able to pick up the node type index, and it will
usually fall back to traversal, which can be quite a punch.
[~tmueller] maybe you could take a look.
> The query engine doesn't properly extract the node type information from
> queries with conditions on jcr:primaryType
> -------------------------------------------------------------------------------------------------------------------
>
> Key: OAK-985
> URL: https://issues.apache.org/jira/browse/OAK-985
> Project: Jackrabbit Oak
> Issue Type: Improvement
> Components: core, query
> Reporter: Alex Parvulescu
>
> Given the following query:
> {code}
> //*[(jcr:contains(., 'dog')) and @jcr:primaryType = 'nt:file']
> {code}
> The query engine will generate a filter with a match-all clause on the node
> type and a property restriction on _jcr:primaryType_ to the value 'nt:file'.
> I think it should add the _jcr:primaryType_ condition to the node type
> conditions, and not to the node property ones.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira