Michael Steiger writes: > > My problem is that I do not know in advance if or when the "index won't > change for some time". I think of running a counter for all updates > (add, delete) and optimize after some threshold. > That's what lucene does anyway. Adding documents means adding segments, and when the number of segments reaches a certain limit, lucene merges these segments. Optimizing also just merges the segments. So if you introduce your own calculation when a merge should be done, your just doubling the effort. OTOH it might be worth thinking about optimizing the index at times, when there won't be much searches on the index (e.g. nightly). Depending on the number of daily updates this might prevent merges during days, when there is more search access (while searches can be done parallel to optimizing, the additional task on the same machine will slow down them a bit). There's are two articles about lucenes indexing details written by Otis Gospodnetic that are linked on the lucene web page, that might be worth reading. Especially the second (Advanced Text Indexing with Lucene).
Morus --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
