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 "Tommaso Teofili (JIRA)" <ji...@apache.org> on 2014/11/26 13:28:12 UTC

[jira] [Commented] (OAK-2298) LuceneIndex should provide correct cost based on index size

    [ https://issues.apache.org/jira/browse/OAK-2298?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14226119#comment-14226119 ] 

Tommaso Teofili commented on OAK-2298:
--------------------------------------

how to calculate the cost for full text queries should be handled a bit differently imho (that's a general issue though), that is because if you have more than one full text index basing the index selection on the no. of docs in the index / results for that query sounds not enough. For indexes that should behave exactly like DBMS indexes (e.g. property index) it's completely fair but for full text indexes it seems to me a more reasonable metric should at least take the highest score in account (or a 10 percentile).
On a related topic I would like to change the Lucene and Solr cost calculation along the same lines (as right now the Solr index behaves similarly to the Lucene one and fundamentally changing the cost calculation would impact, at least, the selection between the Lucene and Solr indexes if both are present).

> LuceneIndex should provide correct cost based on index size
> -----------------------------------------------------------
>
>                 Key: OAK-2298
>                 URL: https://issues.apache.org/jira/browse/OAK-2298
>             Project: Jackrabbit Oak
>          Issue Type: Sub-task
>          Components: oak-lucene
>            Reporter: Chetan Mehrotra
>            Assignee: Chetan Mehrotra
>            Priority: Minor
>             Fix For: 1.2
>
>
> {{LuceneIndex}}  currently provides a hardcoded cost of 10. This causes issue if on same system both old {{LuceneIndex}} and newer {{LucenePropertyIndex}} are configured as former would always win
> To make comparison fair it should report accurate cost based on num of docs in index. Given that {{LuceneIndex}} is only used for fulltext queries it does not have to compete with other property index, it should be safe to provide accurate cost



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