算法调度任务添加
This commit is contained in:
@@ -52,4 +52,13 @@ public class LiteFlowJob {
|
|||||||
liteFlowFeignClient.substationExecutor(baseParam);
|
liteFlowFeignClient.substationExecutor(baseParam);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@XxlJob("deviceJob")
|
||||||
|
public void deviceJob() {
|
||||||
|
BaseParam baseParam = new BaseParam();
|
||||||
|
baseParam.setFullChain(true);
|
||||||
|
baseParam.setRepair(false);
|
||||||
|
baseParam.setDataDate(DateUtil.yesterday().toString(DatePattern.NORM_DATE_PATTERN));
|
||||||
|
liteFlowFeignClient.substationExecutor(baseParam);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -31,4 +31,8 @@ public interface LiteFlowFeignClient {
|
|||||||
@PostMapping("/substationExecutor")
|
@PostMapping("/substationExecutor")
|
||||||
void substationExecutor(@RequestBody BaseParam baseParam);
|
void substationExecutor(@RequestBody BaseParam baseParam);
|
||||||
|
|
||||||
|
@ApiOperation("装置算法执行链")
|
||||||
|
@PostMapping("/deviceExecutor")
|
||||||
|
void deviceExecutor(@RequestBody BaseParam baseParam);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -39,6 +39,12 @@ public class LiteFlowFeignClientFallbackFactory implements FallbackFactory<LiteF
|
|||||||
log.error("{}异常,降级处理,异常为:{}", "变电站算法执行链: ", throwable.toString());
|
log.error("{}异常,降级处理,异常为:{}", "变电站算法执行链: ", throwable.toString());
|
||||||
throw new BusinessException(finalExceptionEnum);
|
throw new BusinessException(finalExceptionEnum);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deviceExecutor(BaseParam baseParam) {
|
||||||
|
log.error("{}异常,降级处理,异常为:{}", "装置算法执行链: ", throwable.toString());
|
||||||
|
throw new BusinessException(finalExceptionEnum);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user