lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Terence Lai <>
Subject Help on the ParallelMultiSearcher.rewrite(Query) method
Date Thu, 07 Jul 2005 19:04:51 GMT
Hi all,

I am currently using Lucene 1.4.2. Since my search documents are huge, I divide the search
index into different index directory and make use of the ParallelMultiSearcher to perform
the search.

Currently, I am working on the highlight feature using Lucene Sandbox Highlighter. One of
the requirements is to convert the Query into the primitive form. I invoked the ParallelMultiSearcher.rewrite(Query).
However, I got the exception, UnsupportedOperationException.

I start studying the source code. I discover that the ParallelMultiSearcher calls Query.combine()
method to combine multiple primitive query into a single one. By looking at the,
the method hasn't been implemented as you see below:

  /** Expert: called when re-writing queries under MultiSearcher.
   * <p>Only implemented by derived queries, with no
   * {@link #createWeight(Searcher)} implementatation.
  public Query combine(Query[] queries) {
    throw new UnsupportedOperationException();

Does anyone know any alternative to rewrite the query if I have multiple index directories?


Get your free email account from
          Your Internet Virtual Desktop!

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

View raw message