In case anyone was interested, making the change I described surfaced a bug that causes the custom similarity to not work. There is a patch: https://issues.apache.org/jira/browse/LUCENE-789
On 5/29/07, Israel Tsadok <[EMAIL PROTECTED]> wrote:
Hi, I am developing a distributed index, using MultiSearcher and RemoteSearcher. When investigating some performance issues, I noticed that there is a lot of back-and-forth traffic between the servers during the weight calculation. Although MultiSearcher has a method called createWeight that minimizes the calls to the sub-searchers, this method never actually gets called when I call search(query). From what I can tell, this is fixable by changing in Hits.java the line: weight = q.weight(s); to: weight = s.createWeight(q); I made that change, and it seems to work OK, but I don't know enough about Lucene to be sure that it's safe. Have I got something wrong? Is it safe to make that change? Thanks, Israel Tsadok