@Configuration
@EnableCaching
public class RedisCacheConfig
extends org.springframework.cache.annotation.CachingConfigurerSupport
Redis Cache配置
Constructor and Description |
---|
RedisCacheConfig() |
Modifier and Type | Method and Description |
---|---|
org.springframework.cache.CacheManager |
cacheManager(org.springframework.data.redis.connection.RedisConnectionFactory factory) |
org.springframework.cache.interceptor.KeyGenerator |
keyGenerator() |
@Bean public org.springframework.cache.interceptor.KeyGenerator keyGenerator()
keyGenerator
in interface org.springframework.cache.annotation.CachingConfigurer
keyGenerator
in class org.springframework.cache.annotation.CachingConfigurerSupport
@Bean public org.springframework.cache.CacheManager cacheManager(org.springframework.data.redis.connection.RedisConnectionFactory factory)
Copyright © 2019. All rights reserved.