| | |
| | | import com.lf.server.service.all.ScheduleService; |
| | | import com.lf.server.service.all.WebSocketService; |
| | | import com.lf.server.service.show.AutoQueryService; |
| | | import com.lf.server.service.show.OneMapService; |
| | | import com.lf.server.service.sys.AttachService; |
| | | import org.apache.commons.logging.Log; |
| | | import org.apache.commons.logging.LogFactory; |
| | | import org.apache.ibatis.annotations.Result; |
| | | import org.springframework.scheduling.annotation.EnableScheduling; |
| | | import org.springframework.scheduling.annotation.Scheduled; |
| | | import org.springframework.stereotype.Component; |
| | |
| | | @Resource |
| | | AutoQueryService autoQueryService; |
| | | |
| | | @Resource |
| | | OneMapService oneMapService; |
| | | |
| | | private static boolean isBusy = false; |
| | | |
| | | private static final Log log = LogFactory.getLog(ScheduleConfig.class); |
| | |
| | | autoQueryService.autoQuery(); |
| | | } |
| | | |
| | | @Scheduled(cron = "0 0 2 * * ?") |
| | | public void calcData() { |
| | | String str = oneMapService.calcData(); |
| | | log.info("计算数据:" + str); |
| | | } |
| | | |
| | | @Scheduled(fixedRate = 15 * 1000) |
| | | public void pushMonitorInfo() { |
| | | try { |