lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bill Gray <>
Subject Analyzers thread safe across indexes?
Date Fri, 25 Jan 2019 00:03:46 GMT

I'm working on an app that will use Lucene and I'm trying to get a handle
of the thread safety of Analyzers.

The specific question I'm exploring is whether it is safe to use a single
instance of an Analyzer across different Indexes (and therefore concurrent
IndexWriters) in the case where two indexes may include the same
Analyzer/fieldName pair?

Our app will create and use multiple indexes concurrently and it is likely
that several of those indexes will contain the same field and specify the
same Analyzer.

It seems like the ReuseStrategy is keyed off Analyzer and fieldName.  So
the Tokenizers would get reused across indexes.  It is not clear to me that
all the Tokenizers are not stateful, but if they are not stateful, then I
guess it would be good to reuse a single Analyzer instance across indexes
in this way?

Thank you.


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message