I originally built the DocSet using SolrIndexSearcher's convertFilter method.

On Henrib's advice, I switched to wrapping the filter in a
ConstantScoreQuery and passing it in with the other filter queries, which
seems easier to manage.

-Doug


hossman wrote:
> 
> 
> : I'm working on a request handler pluging that needs to use a DocSet
> filter
> : (for distance limiting) as well as a list of filter queries to filter
> down a
> : search.  I'm trying to figure out how to best pass that to the
> : SolrIndexSearcher.
> 
> how did you build up the DocSet?  ... typically a DocSet comes from a 
> Query, and you would just add that query to the other list and let 
> getDocList take care of building the DocSet from it.
> 
> : convert the filterList to a DocSet and intersect it with the filter, but
> the
> : method that does that well getDocSet(List<Query> queries) is protected
> 
> thta looks like it may have been because yonik wasn't certain that he 
> wanted to keep it when he first added it ... but it seems like a generally 
> useful method to me (it would need javadocs before it could be made public 
> however)
> 
> : Also, it looks that the getDocListC method, which takes both filter and
> : filterList, actually uses both if it decides to use the filterCache, but
> : only uses one of the two if it takes the else block.  Is that by design?
> 
> this is why even private should have javadocs .. i believe it is only 
> legal to call this method with *either* a DocSet or a List<Query> .. not 
> both  (Yonik: can you confirm?)
> 
> 
> 
> 
> -Hoss
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Getting-a-DocSet-with-a-filter-and-filterList-tf4681959.html#a13407637
Sent from the Solr - Dev mailing list archive at Nabble.com.

Reply via email to