File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
java/io/kimmking/cache/service Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -15,9 +15,9 @@ public class UserServiceImpl implements UserService{
1515UserMapper userMapper ;
1616
1717// 开启spring cache
18- @ Cacheable // (key="#id",value="userCache")
18+ @ Cacheable (key ="#id" ,value ="userCache" )
1919public User find (int id ){
20- // System.out.println(" ==> find " + id);
20+ System .out .println (" ==> find " + id );
2121return userMapper .find (id );
2222 }
2323
Original file line number Diff line number Diff line change @@ -7,13 +7,13 @@ spring:
77password :
88url : jdbc:mysql://localhost:3306/test?useUnicode=true&characterEncoding=utf-8&serverTimezone=UTC
99driver-class-name : com.mysql.jdbc.Driver
10- # cache:
11- # type: redis
10+ cache :
11+ type : redis
1212redis :
1313host : localhost
1414lettuce :
1515pool :
16- max-active : 32
16+ max-active : 16
1717max-wait : 10ms
1818
1919# type: ehcache
You can’t perform that action at this time.
0 commit comments