|
@@ -28,10 +28,19 @@ public class ScheduledTaskController {
|
|
|
|
|
|
@Autowired
|
|
@Autowired
|
|
private ScheduledTaskServiceImpl scheduledTaskService;
|
|
private ScheduledTaskServiceImpl scheduledTaskService;
|
|
|
|
+
|
|
@Scheduled(cron = "0 0 1 * * ?")
|
|
@Scheduled(cron = "0 0 1 * * ?")
|
|
@PostMapping("/routine/inspection")
|
|
@PostMapping("/routine/inspection")
|
|
private R generateRoutineInspectionTask(){
|
|
private R generateRoutineInspectionTask(){
|
|
log.info("开始手动生成任务");
|
|
log.info("开始手动生成任务");
|
|
return scheduledTaskService.generateRoutineInspectionTask();
|
|
return scheduledTaskService.generateRoutineInspectionTask();
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ @Scheduled(cron = "0 0 1 1 12 ?")
|
|
|
|
+ @PostMapping("/partition")
|
|
|
|
+ private R mysqlPartitionCreate(){
|
|
|
|
+ log.info("开始手动生成任务");
|
|
|
|
+ return scheduledTaskService.mysqlPartitionCreate();
|
|
|
|
+ }
|
|
|
|
+
|
|
}
|
|
}
|