Commit 8b28a7a9 authored by duanruiming's avatar duanruiming

[update] 缓存参数刷新

parent 25ac7432
...@@ -6,9 +6,7 @@ import net.wanji.databus.dao.entity.CrossSectionPO; ...@@ -6,9 +6,7 @@ import net.wanji.databus.dao.entity.CrossSectionPO;
import net.wanji.databus.dao.entity.GreenwaveCrossPO; import net.wanji.databus.dao.entity.GreenwaveCrossPO;
import net.wanji.databus.dao.mapper.BaseCrossSchemeMapper; import net.wanji.databus.dao.mapper.BaseCrossSchemeMapper;
import net.wanji.databus.dao.mapper.BaseCrossSectionMapper; import net.wanji.databus.dao.mapper.BaseCrossSectionMapper;
import net.wanji.datacenter.cache.CrossGreenWaveInfoCache; import net.wanji.datacenter.cache.*;
import net.wanji.datacenter.cache.CrossSchemePhaseLightsCache;
import net.wanji.datacenter.cache.WeekDirFreeFlowSpeedCache;
import net.wanji.datacenter.pojo.dto.CrossSchemePhaseDirTurnDTO; import net.wanji.datacenter.pojo.dto.CrossSchemePhaseDirTurnDTO;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.springframework.scheduling.annotation.Scheduled; import org.springframework.scheduling.annotation.Scheduled;
...@@ -32,6 +30,12 @@ public class DataCenterTask { ...@@ -32,6 +30,12 @@ public class DataCenterTask {
@Resource @Resource
private WeekDirFreeFlowSpeedCache weekDirFreeFlowSpeedCache; private WeekDirFreeFlowSpeedCache weekDirFreeFlowSpeedCache;
@Resource
private WeekTurnFreeFlowSpeedCache weekTurnFreeFlowSpeedCache;
@Resource
private CrossDirWeekAvgFlowCache crossDirWeekAvgFlowCache;
@Resource
private CrossDirWeekMaxFlowCache crossDirWeekMaxFlowCache;
@Resource @Resource
private BaseCrossSectionMapper baseCrossSectionMapper; private BaseCrossSectionMapper baseCrossSectionMapper;
...@@ -41,6 +45,9 @@ public class DataCenterTask { ...@@ -41,6 +45,9 @@ public class DataCenterTask {
@Scheduled(cron = "0 0 0 * * ?") @Scheduled(cron = "0 0 0 * * ?")
public void getWeekFreeFlowSpeed() throws Exception { public void getWeekFreeFlowSpeed() throws Exception {
weekDirFreeFlowSpeedCache.run(); weekDirFreeFlowSpeedCache.run();
weekTurnFreeFlowSpeedCache.run();
crossDirWeekAvgFlowCache.run();
crossDirWeekMaxFlowCache.run();
} }
@Scheduled(initialDelay = 1000 * 60, fixedRate = 1000 * 60 * 60) @Scheduled(initialDelay = 1000 * 60, fixedRate = 1000 * 60 * 60)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment