Commit eb89a1e2f8d7c09289fbe5469d9593eb5bda1f8b
1 parent
05cb8a9e
update...
Showing
1 changed file
with
2 additions
and
1 deletions
src/main/java/com/bsth/redis/ScheduleRedisService.java
| ... | ... | @@ -222,7 +222,7 @@ public class ScheduleRedisService implements CommandLineRunner { |
| 222 | 222 | wirte(list); |
| 223 | 223 | |
| 224 | 224 | //定时刷新一次当日实际排班 |
| 225 | - int minute = 30; | |
| 225 | + int minute = 2; | |
| 226 | 226 | Application.mainServices.scheduleWithFixedDelay(scheduleRefreshThread, minute, minute, TimeUnit.MINUTES); |
| 227 | 227 | //24小时清理一次实际排班数据 |
| 228 | 228 | Application.mainServices.scheduleWithFixedDelay(scheduleClearThread, 24, 24, TimeUnit.HOURS); |
| ... | ... | @@ -250,6 +250,7 @@ public class ScheduleRedisService implements CommandLineRunner { |
| 250 | 250 | public void run() { |
| 251 | 251 | try { |
| 252 | 252 | DateTime dt = new DateTime(); |
| 253 | + logger.info("ScheduleRefreshThread..." + dt.toString("yyyy-MM-dd")); | |
| 253 | 254 | List<ScheduleRealInfo> list = realInfoRepository.findAll(dt.toString("yyyy-MM-dd")); |
| 254 | 255 | scheduleRedisService.wirte(list); |
| 255 | 256 | } catch (Exception e) { | ... | ... |