Hi all,

I have the following scenario: I want to use ParallelReader to maintain parts of the index that are changing quickly, and where changes are limited to specific fields only.

Let's say I have a "main" index (many fields, slowly changing, large updates), and an "aux" index (fast changing, usually single doc and single field updates). I'd like to "replace" documents in the "aux" index - that is, delete one doc and add another - but in a way that doesn't change the internal document numbers, so that I can keep the mapping required by ParallelReader intact.

I think this is possible to achieve by using a FilterIndexReader, which keeps a map of updated documents, and re-maps old doc ids to the new ones on the fly.

From time to time I'd like to optimize the "aux" index to get rid of deleted docs. At this time I need to figure out how to preserve the old->new mapping during the optimization.

So, here's the question: is this scenario feasible? If so, then in the trunk/ version of Lucene, is there any way to figure out (predictably) how internal document numbers are reassigned after calling optimize() ?

--
Best regards,
Andrzej Bialecki     <><
 ___. ___ ___ ___ _ _   __________________________________
[__ || __|__/|__||\/|  Information Retrieval, Semantic Web
___|||__||  \|  ||  |  Embedded Unix, System Integration
http://www.sigram.com  Contact: info at sigram dot com


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to