You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Julian Reschke (JIRA)" <ji...@apache.org> on 2016/11/10 10:01:58 UTC

[jira] [Updated] (OAK-4904) For unique indexes avoid consulting indexes other than property index

     [ https://issues.apache.org/jira/browse/OAK-4904?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Julian Reschke updated OAK-4904:
--------------------------------
    Fix Version/s: 1.6

> For unique indexes avoid consulting indexes other than property index
> ---------------------------------------------------------------------
>
>                 Key: OAK-4904
>                 URL: https://issues.apache.org/jira/browse/OAK-4904
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: query
>            Reporter: Chetan Mehrotra
>            Assignee: Thomas Mueller
>              Labels: candidate_oak_1_4, performance
>             Fix For: 1.6, 1.5.12
>
>         Attachments: OAK-4904-v1.patch, OAK-4904-v2.patch
>
>
> Currently for queries involving unique index like 
> {noformat}
> SELECT * FROM [nt:base] WHERE [jcr:uuid] = $id
> {noformat}
> QueryEngine would start consulting all types of index in order of minimum cost. Where minimum cost are
> * PropertyIndex - 2.0
> * LucenePropertyIndex - 2.1
> For such queries in case of match property index returns a cost of (base) 2 + (count) 1 = 3 due to which QE has to consult Lucene index also. Given such queries a very frequent it would be better to avoid consulting Lucene index as that adds unnecessary overhead



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)