Class MultiLevelCacheManager

java.lang.Object
io.github.suppie.spring.cache.MultiLevelCacheManager
All Implemented Interfaces:
org.springframework.cache.CacheManager

public class MultiLevelCacheManager extends Object implements org.springframework.cache.CacheManager
Cache manager to cover basic operations
  • Constructor Details

    • MultiLevelCacheManager

      public MultiLevelCacheManager(org.springframework.beans.factory.ObjectProvider<org.springframework.boot.autoconfigure.cache.CacheProperties> highLevelProperties, MultiLevelCacheConfigurationProperties properties, org.springframework.data.redis.core.RedisTemplate<Object,Object> redisTemplate, io.github.resilience4j.circuitbreaker.CircuitBreaker circuitBreaker)
  • Method Details

    • getCache

      public org.springframework.cache.Cache getCache(@NonNull String name)
      Get or create the cache associated with the given name.
      Specified by:
      getCache in interface org.springframework.cache.CacheManager
      Parameters:
      name - the cache identifier (must not be null)
      Returns:
      the associated cache, or null if such a cache does not exist or could be not created
    • getCacheNames

      public @NonNull Collection<String> getCacheNames()
      Get a collection of the cache names known by this manager.
      Specified by:
      getCacheNames in interface org.springframework.cache.CacheManager
      Returns:
      the names of all caches known by the cache manager