Return-Path: Delivered-To: apmail-lucene-java-user-archive@www.apache.org Received: (qmail 15076 invoked from network); 7 Jul 2005 19:05:03 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 7 Jul 2005 19:05:03 -0000 Received: (qmail 27554 invoked by uid 500); 7 Jul 2005 19:04:55 -0000 Delivered-To: apmail-lucene-java-user-archive@lucene.apache.org Received: (qmail 27532 invoked by uid 500); 7 Jul 2005 19:04:55 -0000 Mailing-List: contact java-user-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-user@lucene.apache.org Delivered-To: mailing list java-user@lucene.apache.org Received: (qmail 27518 invoked by uid 99); 7 Jul 2005 19:04:55 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 Jul 2005 12:04:55 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [207.245.223.231] (HELO trekspace.trekspace.com) (207.245.223.231) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 Jul 2005 12:04:53 -0700 Received: from trekspace.trekspace.com (trekspace@trekspace.trekspace.com [192.168.2.234]) by trekspace.trekspace.com (8.12.3/8.12.3/Debian-7.1) with ESMTP id j67J4pZZ016369 for ; Thu, 7 Jul 2005 15:04:51 -0400 Message-ID: <9050778747856585878CMPYMWVNLK.tlai@trekspace.com> Date: Thu, 7 Jul 2005 15:04:51 -0400 (EDT) From: Terence Lai Reply-To: Terence Lai To: java-user@lucene.apache.org Subject: Help on the ParallelMultiSearcher.rewrite(Query) method Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Mailer: Treklogic MailTool v1.6 http://www.treklogic.com X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N 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 Query.java, the method hasn't been implemented as you see below: /** Expert: called when re-writing queries under MultiSearcher. * *

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? Thanks, Terence ---------------------------------------------------------- Get your free email account from http://www.trekspace.com Your Internet Virtual Desktop! --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org For additional commands, e-mail: java-user-help@lucene.apache.org