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

Amrit Verma reassigned OAK-9480:
--------------------------------

    Assignee: Amrit Verma

> Log a warning for improper usage of an index with valueRegex set
> ----------------------------------------------------------------
>
>                 Key: OAK-9480
>                 URL: https://issues.apache.org/jira/browse/OAK-9480
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: indexing
>            Reporter: Amrit Verma
>            Assignee: Amrit Verma
>            Priority: Major
>
> Index definitions which have the {{valueRegex}} property (introduced in 
> OAK-8934) set, cause the resulting indices to only have those values indexed 
> which match that regex.
> However at query time, we are allowing query for all values (irrespective of 
> whether they match the {{valueRegex}}) against such indices, which might 
> result in the query returning no results.
> While solving it completely could be complex for fulltext queries (as seen in 
> example below), we should start with logging a warning if we detect mismatch 
> between query term and {{valueRegex}}.
> Example 1 -
> valueRegex=(["']|^)/
> stored value=/content/test
> query term=hello
> In this case, query term doesn't match valueRegex and it is also not 
> contained in the index.
> Example 2 -
> valueRegex = oak.*
> stored value = oak - the next generation content repository
> query term = repository
> Query term doesn't match the valueRegex, but it still could still be searched 
> and would return the node.
>  
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to