|
|
@ -116,7 +116,7 @@ public class JobThread extends Thread{
|
|
|
|
triggerLogIdSet.remove(triggerParam.getLogId());
|
|
|
|
triggerLogIdSet.remove(triggerParam.getLogId());
|
|
|
|
|
|
|
|
|
|
|
|
// log filename, like "logPath/yyyy-MM-dd/9999.log"
|
|
|
|
// log filename, like "logPath/yyyy-MM-dd/9999.log"
|
|
|
|
String logFileName = XxlJobFileAppender.makeLogFileName(new Date(triggerParam.getLogDateTim()), triggerParam.getLogId());
|
|
|
|
String logFileName = XxlJobFileAppender.makeLogFileName(new Date(triggerParam.getLogDateTime()), triggerParam.getLogId());
|
|
|
|
XxlJobFileAppender.contextHolder.set(logFileName);
|
|
|
|
XxlJobFileAppender.contextHolder.set(logFileName);
|
|
|
|
ShardingUtil.setShardingVo(new ShardingUtil.ShardingVO(triggerParam.getBroadcastIndex(), triggerParam.getBroadcastTotal()));
|
|
|
|
ShardingUtil.setShardingVo(new ShardingUtil.ShardingVO(triggerParam.getBroadcastIndex(), triggerParam.getBroadcastTotal()));
|
|
|
|
|
|
|
|
|
|
|
@ -186,11 +186,11 @@ public class JobThread extends Thread{
|
|
|
|
// callback handler info
|
|
|
|
// callback handler info
|
|
|
|
if (!toStop) {
|
|
|
|
if (!toStop) {
|
|
|
|
// commonm
|
|
|
|
// commonm
|
|
|
|
TriggerCallbackThread.pushCallBack(new HandleCallbackParam(triggerParam.getLogId(), triggerParam.getLogDateTim(), executeResult));
|
|
|
|
TriggerCallbackThread.pushCallBack(new HandleCallbackParam(triggerParam.getLogId(), triggerParam.getLogDateTime(), executeResult));
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
// is killed
|
|
|
|
// is killed
|
|
|
|
ReturnT<String> stopResult = new ReturnT<String>(ReturnT.FAIL_CODE, stopReason + " [job running,killed]");
|
|
|
|
ReturnT<String> stopResult = new ReturnT<String>(ReturnT.FAIL_CODE, stopReason + " [job running,killed]");
|
|
|
|
TriggerCallbackThread.pushCallBack(new HandleCallbackParam(triggerParam.getLogId(), triggerParam.getLogDateTim(), stopResult));
|
|
|
|
TriggerCallbackThread.pushCallBack(new HandleCallbackParam(triggerParam.getLogId(), triggerParam.getLogDateTime(), stopResult));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -202,7 +202,7 @@ public class JobThread extends Thread{
|
|
|
|
if (triggerParam!=null) {
|
|
|
|
if (triggerParam!=null) {
|
|
|
|
// is killed
|
|
|
|
// is killed
|
|
|
|
ReturnT<String> stopResult = new ReturnT<String>(ReturnT.FAIL_CODE, stopReason + " [job not executed, in the job queue, killed.]");
|
|
|
|
ReturnT<String> stopResult = new ReturnT<String>(ReturnT.FAIL_CODE, stopReason + " [job not executed, in the job queue, killed.]");
|
|
|
|
TriggerCallbackThread.pushCallBack(new HandleCallbackParam(triggerParam.getLogId(), triggerParam.getLogDateTim(), stopResult));
|
|
|
|
TriggerCallbackThread.pushCallBack(new HandleCallbackParam(triggerParam.getLogId(), triggerParam.getLogDateTime(), stopResult));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|