Browse Source

定时任务开启缓存数据功能

zyg 1 year ago
parent
commit
b23bc2eba5

+ 1 - 1
hz-business/src/main/java/com/hz/business/scheduler/JobScheduler.java

@@ -224,7 +224,7 @@ public class JobScheduler {
      * 定时缓存页面数据
      * 5分钟一次
      */
-    //@Scheduled(cron = "0 */5 * * * ?")
+    @Scheduled(cron = "0 */5 * * * ?")
     public void setCache() {
         SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
         log.info("当前时间{},开始缓存",sdf.format(new Date()));