Springboot集成Ehcache,并结合CommandLineRunner接口实现Springboot项目启动时热加载数据库数据至缓存
1、Springboot开启缓存,并引入ehcache依赖。
<!-- 开启cache缓存 -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-cache</artifactId>
&l...
原创
2018-12-11 00:30:04 ·
1957 阅读 ·
1 评论