Class SolrPluginUtils.IdentityRegenerator

  • All Implemented Interfaces:
    Enclosing class:

    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 Detail

      • IdentityRegenerator

        public IdentityRegenerator()
    • 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 into newCache
        Specified by:
        regenerateItem in interface CacheRegenerator
        newSearcher - the new searcher who's caches are being autowarmed
        newCache - where regenerated cache items should be stored. the target of the autowarming
        oldCache - the old cache being used as a source for autowarming
        oldKey - the key of the old cache item to regenerate in the new cache
        oldVal - the old value of the cache item
        true to continue with autowarming, false to stop