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

Tim Sturge updated LUCENE-1461:
-------------------------------

    Attachment: RangeMultiFilter.java

This is a version of RangeMultiFilter built on top of FieldCache. This is much 
cleaner; it automatically handles changing the IndexReader and no longer 
requires the user to manually build a separate DisjointMultiFilter.

Performance is the same:

Cached Range Filter:
startup: 2
Hits: 167390
first query: 2009
100 queries: 4733

RangeMultiFilter + FieldCache
startup: 0
Hits: 167390
first query: 5405
100 queries: 8091

ConstantScoreRangeQuery
startup: 3
Hits: 167390
first query: 2012
100 queries: 56620

Boolean Query for Range
startup: 0
Hits: 121151
first query: 3518
100 queries: 118690





> Cached filter for a single term field
> -------------------------------------
>
>                 Key: LUCENE-1461
>                 URL: https://issues.apache.org/jira/browse/LUCENE-1461
>             Project: Lucene - Java
>          Issue Type: New Feature
>            Reporter: Tim Sturge
>         Attachments: DisjointMultiFilter.java, RangeMultiFilter.java, 
> RangeMultiFilter.java, TermMultiFilter.java
>
>
> These classes implement inexpensive range filtering over a field containing a 
> single term. They do this by building an integer array of term numbers 
> (storing the term->number mapping in a TreeMap) and then implementing a fast 
> integer comparison based DocSetIdIterator.
> This code is currently being used to do age range filtering, but could also 
> be used to do other date filtering or in any application where there need to 
> be multiple filters based on the same single term field. I have an untested 
> implementation of single term filtering and have considered but not yet 
> implemented term set filtering (useful for location based searches) as well. 
> The code here is fairly rough; it works but lacks javadocs and toString() and 
> hashCode() methods etc. I'm posting it here to discover if there is other 
> interest in this feature; I don't mind fixing it up but would hate to go to 
> the effort if it's not going to make it into Lucene.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to