From 0b9c144b5110a7e2a85b2e5581ef304bb81a3ebc Mon Sep 17 00:00:00 2001 From: jiangping <jp@doumee.com> Date: 星期二, 19 九月 2023 19:24:35 +0800 Subject: [PATCH] 修改 --- server/platform/src/main/java/com/doumee/task/ScheduleTool.java | 23 +++++++++++++++++++---- 1 files changed, 19 insertions(+), 4 deletions(-) diff --git a/server/platform/src/main/java/com/doumee/task/ScheduleTool.java b/server/platform/src/main/java/com/doumee/task/ScheduleTool.java index 9c105aa..00d40f0 100644 --- a/server/platform/src/main/java/com/doumee/task/ScheduleTool.java +++ b/server/platform/src/main/java/com/doumee/task/ScheduleTool.java @@ -1,6 +1,9 @@ package com.doumee.task; +import com.doumee.service.business.BaseDataService; +import com.doumee.service.business.FileRecordService; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.scheduling.annotation.EnableScheduling; import org.springframework.scheduling.annotation.Scheduled; import org.springframework.stereotype.Component; @@ -15,14 +18,26 @@ @EnableScheduling public class ScheduleTool { + @Autowired + private BaseDataService baseDataService; + @Autowired + private FileRecordService fileRecordService; /** - * 缂撳瓨鐪佸競鍖� + * 瀹氭椂澶勭悊鐖櫕婧愭暟鎹紝鐢熸垚绱犳潗搴撴暟鎹� * @throws Exception */ - @Scheduled(fixedDelay=24*60*60*1000) - public void cacheCampus() throws Exception { - + @Scheduled(fixedDelay=30*60*1000) + public void dealBaseData() throws Exception { + baseDataService.dealBaseData(); + } + /** + * 瀹氭椂澶勭悊鐖櫕婧愭暟鎹紝鐢熸垚绱犳潗搴撴暟鎹� + * @throws Exception + */ + @Scheduled(fixedDelay=30*60*1000,initialDelay = 30000) + public void dealOploadEvent() throws Exception { + fileRecordService.dealOploadEvent(); } } -- Gitblit v1.9.3