You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by Earl Hood <ea...@gmail.com> on 2012/12/05 08:33:12 UTC

Is Analyzer used when calling IndexWriter.addIndexesNoOptimize()?

Lucene version: 3.0.3

Does IndexWriter use the analyzer when adding indexes via
addIndexesNoOptimize()?

What about for optimize()?

I am examining some existing code and trying to determine
what effects there may be when combining multiple indexes
into a single index, but each index may have had different
analyzers used.

Thanks,

--ewh

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Re: Is Analyzer used when calling IndexWriter.addIndexesNoOptimize()?

Posted by Earl Hood <ea...@earlhood.com>.
On Wed, Dec 5, 2012 at 8:24 AM, Jack Krupansky wrote:

> These are operations on indexes, so analysis is no longer relevant. Analysis
> is performed BEFORE data is placed in an index. You still need to perform
> analysis for queries though.

This is what I thought.  Just wanted to get confirmation.

> Rule #1 with Lucene and Solr - always be prepared to completely reindex your
> data, precisely because ideas about analysis evolve over time.

Unfortunately, re-indexing is not something that can be done easily in
the project I am on.  Hence, upgrading Lucene always has to be
considered carefully.

The problem is also further compounded by some organizations that want
to customize how there data gets indexed, with a single application then
having to be able to search across the normal and customized indexes.

Thanks for the response,

--ewh

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Re: Is Analyzer used when calling IndexWriter.addIndexesNoOptimize()?

Posted by Jack Krupansky <ja...@basetechnology.com>.
These are operations on indexes, so analysis is no longer relevant. Analysis 
is performed BEFORE data is placed in an index. You still need to perform 
analysis for queries though.

You can use different analyzers as long as they are compatible - if they 
produce the same results, but if they don't produce the same token stream at 
both the token and character/byte level, your queries may fail.

Rule #1 with Lucene and Solr - always be prepared to completely reindex your 
data, precisely because ideas about analysis evolve over time.

-- Jack Krupansky

-----Original Message----- 
From: Earl Hood
Sent: Wednesday, December 05, 2012 2:33 AM
To: java-user@lucene.apache.org
Subject: Is Analyzer used when calling IndexWriter.addIndexesNoOptimize()?

Lucene version: 3.0.3

Does IndexWriter use the analyzer when adding indexes via
addIndexesNoOptimize()?

What about for optimize()?

I am examining some existing code and trying to determine
what effects there may be when combining multiple indexes
into a single index, but each index may have had different
analyzers used.

Thanks,

--ewh

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org 


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org