Package org.apache.solr.util
Class SolrPluginUtils.IdentityRegenerator
- java.lang.Object
-
- org.apache.solr.util.SolrPluginUtils.IdentityRegenerator
-
- All Implemented Interfaces:
CacheRegenerator
- Enclosing class:
- SolrPluginUtils
public static class SolrPluginUtils.IdentityRegenerator extends Object implements CacheRegenerator
A CacheRegenerator that can be used whenever the items in the cache are not dependant on the current searcher.Flat out copies the oldKey=>oldVal pair into the newCache
-
-
Constructor Summary
Constructors Constructor Description IdentityRegenerator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
regenerateItem(SolrIndexSearcher newSearcher, SolrCache newCache, SolrCache oldCache, Object oldKey, Object oldVal)
Regenerate an old cache item and insert it intonewCache
-
-
-
Method Detail
-
regenerateItem
public boolean regenerateItem(SolrIndexSearcher newSearcher, SolrCache newCache, SolrCache oldCache, Object oldKey, Object oldVal) throws IOException
Description copied from interface:CacheRegenerator
Regenerate an old cache item and insert it intonewCache
- Specified by:
regenerateItem
in interfaceCacheRegenerator
- Parameters:
newSearcher
- the new searcher who's caches are being autowarmednewCache
- where regenerated cache items should be stored. the target of the autowarmingoldCache
- the old cache being used as a source for autowarmingoldKey
- the key of the old cache item to regenerate in the new cacheoldVal
- the old value of the cache item- Returns:
- true to continue with autowarming, false to stop
- Throws:
IOException
-
-