|
@@ -3,6 +3,7 @@ package com.example.mdd.job;
|
|
|
import com.example.mdd.service.MeteorologicalDataDownload;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
import org.springframework.scheduling.annotation.EnableScheduling;
|
|
|
+import org.springframework.scheduling.annotation.Scheduled;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
import javax.annotation.Resource;
|
|
@@ -17,7 +18,7 @@ public class DownloadHour {
|
|
|
|
|
|
//每小时下载数据
|
|
|
//@Scheduled(fixedDelay = 1000)
|
|
|
- //@Scheduled(cron = "0 0 0/1 * * ?")
|
|
|
+ @Scheduled(cron = "0 0 0/1 * * ?")
|
|
|
public void download() {
|
|
|
md.downloadHour();
|
|
|
}
|