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

Matt Weber commented on LUCENE-8828:
------------------------------------

[~romseygeek] Sounds good thanks!

> Fix Intervals.unordered() without overlaps
> ------------------------------------------
>
>                 Key: LUCENE-8828
>                 URL: https://issues.apache.org/jira/browse/LUCENE-8828
>             Project: Lucene - Core
>          Issue Type: Improvement
>            Reporter: Alan Woodward
>            Assignee: Alan Woodward
>            Priority: Major
>         Attachments: LUCENE-8828.patch
>
>
> LUCENE-8300 added an option to Intervals.unordered() which would attempt to 
> find intervals that contained all of a set of subintervals where none of the 
> subintervals overlapped.  Unfortunately, this implementation was buggy, and 
> could miss documents depending on the order in which the subintervals were 
> passed to the factory method.
> After some digging around, I think that it is not in fact possible to 
> implement this in anything other than n! time, because of the need to 
> minimize the resulting intervals.  My proposal is to remove the boolean flag, 
> and instead implement an Intervals.unorderedNoOverlaps() method that takes 
> only two subsources, and rewrites NO_OVERLAPS(a, b) to OR(ORDERED(a, b), 
> ORDERED(b, a)).  The usual simplifications will apply here, so NO_OVERLAPS(a, 
> a) will end up as ORDERED(a, a)



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to