lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yonik Seeley" <>
Subject Re: MultiReader and MultiSearcher
Date Tue, 11 Apr 2006 15:10:08 GMT
On 4/11/06, Peter Keegan <> wrote:
> Could you explain why an IndexSearcher constructed from multiple readers is
> faster than a MultiSearcher constructed from same readers?

The "convergence layer" is a level lower for a MultiReader vs a MultiSearcher.

A MultiReader is an IndexReader, and Queries (Scorers) run directly
against it since it has efficient TermEnum and TermDocs

A MultiSearcher must do independent searches against subsearchers
retrieving the top "n" matches, and maintain an additional priority
queue to merge the results to get the global top "n" matches.  The
implemetation of createWeight is also heavier (heh..)

I've never measured the performance difference, and it's probably
relatively small for most queries.

-Yonik Solr, The Open Source Lucene Search Server

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message