🏗️ 将缓存框架由 Spring Boot Cache 改为 Alibaba JetCache, 支持缓存自动刷新

This commit is contained in:
zhaojun1998
2019-12-29 19:09:50 +08:00
parent 099c09b625
commit 6a54150868
13 changed files with 79 additions and 115 deletions

View File

@@ -1,8 +1,9 @@
package im.zhaojun;
import com.alicp.jetcache.anno.config.EnableCreateCacheAnnotation;
import com.alicp.jetcache.anno.config.EnableMethodCache;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cache.annotation.EnableCaching;
import org.springframework.context.annotation.EnableAspectJAutoProxy;
import org.springframework.scheduling.annotation.EnableAsync;
@@ -11,7 +12,8 @@ import org.springframework.scheduling.annotation.EnableAsync;
*/
@EnableAsync
@SpringBootApplication
@EnableCaching
@EnableMethodCache(basePackages = "im.zhaojun", proxyTargetClass = true)
@EnableCreateCacheAnnotation
@EnableAspectJAutoProxy(exposeProxy = true)
public class ZfileApplication {