On 4/23/2018 11:56 PM, Papa Pappu wrote:
> I've written down my query over stack-overflow. Here is the link for that :
> https://stackoverflow.com/questions/49993681/preventing-solr-cache-flush-when-commiting
>
> In short, I am facing troubles maintaining my solr caches when commits
> happen and the question provides detailed description of the same.

The information in Solr caches rely on Lucene internal doc IDs.

When changes to the index happen and a new searcher is created, there is
absolutely no guarantee that the Lucene document IDs will be the same as
they were on the old searcher.  Solr must assume that the IDs are
different, so it has no choice but to throw away its cache entries when
a new searcher is created.

> Based on my use-case if someone can recommend what settings I should use or
> practices I should follow it'll be really helpful.

This is similar information as you got in the SO post.  You can rely on
newSearcher cache warming, and the autowarming configured in the caches
themselves.  Be careful about making autowarmCount too large.  Large
values there can make commits very slow.

The basic advice for getting the most out of Solr caches is to put off
opening new searchers as long as you can.  Commit less frequently.

Thanks,
Shawn

Reply via email to