Browse Source

定时任务 Host判断

tags/24080901
PoffyZhang 1 year ago
parent
commit
738f6efc42
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      pmapi/src/main/java/com/ningdatech/pmapi/scheduler/task/CheckProvincialReviewResultTask.java

+ 2
- 2
pmapi/src/main/java/com/ningdatech/pmapi/scheduler/task/CheckProvincialReviewResultTask.java View File

@@ -39,10 +39,10 @@ public class CheckProvincialReviewResultTask {
private final IProjectService projectService;
private final StateMachineUtils stateMachineUtils;

@Scheduled(cron = "0 */1 * * * ?")
@Scheduled(cron = "0 */5 * * * ?")
public void statusFlow() throws UnknownHostException {
//测试暂时用自己电脑HOST
if (TaskContant.Host.HOST_ZPF.equals(InetAddress.getLocalHost().getHostName())) {
if (TaskContant.Host.HOST_207.equals(InetAddress.getLocalHost().getHostName())) {
//1. 定时取 省级部门联审中的项目 去取项目
List<Project> projectList = projectService.list(Wrappers.lambdaQuery(Project.class)
.eq(Project::getStage, ProjectStatusEnum.NOT_APPROVED.getCode())


Loading…
Cancel
Save