提交 dd7b1b1d 编写于 作者: T Tboy 提交者: dailidong

move updateTaskState into try/catch block in case of exception (#1003)

* move updateTaskState into try/catch block in case of exception

* fix NPE
上级 370e55fd
......@@ -450,6 +450,7 @@ public class SchedulerService extends BaseService {
Schedule schedule = processDao.querySchedule(scheduleId);
if (schedule == null) {
logger.warn("process schedule info not exists");
return;
}
Date startDate = schedule.getStartTime();
......
......@@ -129,7 +129,7 @@ public class PropertyUtils {
return Boolean.parseBoolean(value);
}
return null;
return false;
}
/**
......
......@@ -82,10 +82,10 @@ public class TaskScheduleThread implements Runnable {
@Override
public void run() {
// update task state is running according to task type
updateTaskState(taskInstance.getTaskType());
try {
// update task state is running according to task type
updateTaskState(taskInstance.getTaskType());
logger.info("script path : {}", taskInstance.getExecutePath());
// task node
TaskNode taskNode = JSONObject.parseObject(taskInstance.getTaskJson(), TaskNode.class);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册