核心依赖Core内部国际化处理;

v1.9.2
xuxueli 6 years ago
parent d9355f421f
commit ff4378e1ce

@ -1234,6 +1234,7 @@ Tips: 历史版本(V1.3.x)目前已经Release至稳定版本, 进入维护阶段
- 15、脚本任务Log文件流关闭优化 - 15、脚本任务Log文件流关闭优化
- 16、任务报表成功、失败和进行中统计问题修复 - 16、任务报表成功、失败和进行中统计问题修复
- 17、自研Log组件参数占位符改为"{}",并修复打印有参日志时参数不匹配导致报错的问题; - 17、自研Log组件参数占位符改为"{}",并修复打印有参日志时参数不匹配导致报错的问题;
- 18、核心依赖Core内部国际化处理
### TODO LIST ### TODO LIST
@ -1255,10 +1256,9 @@ Tips: 历史版本(V1.3.x)目前已经Release至稳定版本, 进入维护阶段
- 16、新增任务默认运行状态任务更新时运行状态保持不变 - 16、新增任务默认运行状态任务更新时运行状态保持不变
- 17、提供多版本执行器不依赖容器版本、不内嵌Jetty版本通过配置executoraddress替换jetty通讯 - 17、提供多版本执行器不依赖容器版本、不内嵌Jetty版本通过配置executoraddress替换jetty通讯
- 18、注册中心支持扩展除默认基于DB之外支持扩展接入第三方注册中心如zk、eureka等 - 18、注册中心支持扩展除默认基于DB之外支持扩展接入第三方注册中心如zk、eureka等
- 19、依赖Core内部国际化处理 - 19、流程任务支持参数传递
- 20、流程任务支持参数传递 - 20、SimpleTrigger 支持;
- 21、SimpleTrigger 支持; - 21、支持通过API服务操作任务信息
- 22、支持通过API服务操作任务信息
## 七、其他 ## 七、其他

@ -50,7 +50,7 @@ public class ExecutorBizImpl implements ExecutorBiz {
// kill handlerThread, and create new one // kill handlerThread, and create new one
JobThread jobThread = XxlJobExecutor.loadJobThread(jobId); JobThread jobThread = XxlJobExecutor.loadJobThread(jobId);
if (jobThread != null) { if (jobThread != null) {
XxlJobExecutor.removeJobThread(jobId, "人工手动终止"); XxlJobExecutor.removeJobThread(jobId, "scheduling center kill job.");
return ReturnT.SUCCESS; return ReturnT.SUCCESS;
} }
@ -83,7 +83,7 @@ public class ExecutorBizImpl implements ExecutorBiz {
// valid old jobThread // valid old jobThread
if (jobThread!=null && jobHandler != newJobHandler) { if (jobThread!=null && jobHandler != newJobHandler) {
// change handler, need kill old thread // change handler, need kill old thread
removeOldReason = "更换JobHandler或更换任务模式,终止旧任务线程"; removeOldReason = "change jobhandler or glue type, and terminate the old job thread.";
jobThread = null; jobThread = null;
jobHandler = null; jobHandler = null;
@ -104,7 +104,7 @@ public class ExecutorBizImpl implements ExecutorBiz {
!(jobThread.getHandler() instanceof GlueJobHandler !(jobThread.getHandler() instanceof GlueJobHandler
&& ((GlueJobHandler) jobThread.getHandler()).getGlueUpdatetime()==triggerParam.getGlueUpdatetime() )) { && ((GlueJobHandler) jobThread.getHandler()).getGlueUpdatetime()==triggerParam.getGlueUpdatetime() )) {
// change handler or gluesource updated, need kill old thread // change handler or gluesource updated, need kill old thread
removeOldReason = "更新任务逻辑或更换任务模式,终止旧任务线程"; removeOldReason = "change job source or glue type, and terminate the old job thread.";
jobThread = null; jobThread = null;
jobHandler = null; jobHandler = null;
@ -127,7 +127,7 @@ public class ExecutorBizImpl implements ExecutorBiz {
!(jobThread.getHandler() instanceof ScriptJobHandler !(jobThread.getHandler() instanceof ScriptJobHandler
&& ((ScriptJobHandler) jobThread.getHandler()).getGlueUpdatetime()==triggerParam.getGlueUpdatetime() )) { && ((ScriptJobHandler) jobThread.getHandler()).getGlueUpdatetime()==triggerParam.getGlueUpdatetime() )) {
// change script or gluesource updated, need kill old thread // change script or gluesource updated, need kill old thread
removeOldReason = "更新任务逻辑或更换任务模式,终止旧任务线程"; removeOldReason = "change job source or glue type, and terminate the old job thread.";
jobThread = null; jobThread = null;
jobHandler = null; jobHandler = null;
@ -147,12 +147,12 @@ public class ExecutorBizImpl implements ExecutorBiz {
if (ExecutorBlockStrategyEnum.DISCARD_LATER == blockStrategy) { if (ExecutorBlockStrategyEnum.DISCARD_LATER == blockStrategy) {
// discard when running // discard when running
if (jobThread.isRunningOrHasQueue()) { if (jobThread.isRunningOrHasQueue()) {
return new ReturnT<String>(ReturnT.FAIL_CODE, "阻塞处理策略-生效"+ExecutorBlockStrategyEnum.DISCARD_LATER.getTitle()); return new ReturnT<String>(ReturnT.FAIL_CODE, "block strategy effect"+ExecutorBlockStrategyEnum.DISCARD_LATER.getTitle());
} }
} else if (ExecutorBlockStrategyEnum.COVER_EARLY == blockStrategy) { } else if (ExecutorBlockStrategyEnum.COVER_EARLY == blockStrategy) {
// kill running jobThread // kill running jobThread
if (jobThread.isRunningOrHasQueue()) { if (jobThread.isRunningOrHasQueue()) {
removeOldReason = "阻塞处理策略-生效" + ExecutorBlockStrategyEnum.COVER_EARLY.getTitle(); removeOldReason = "block strategy effect" + ExecutorBlockStrategyEnum.COVER_EARLY.getTitle();
jobThread = null; jobThread = null;
} }

@ -91,7 +91,7 @@ public class XxlJobExecutor implements ApplicationContextAware {
// destory JobThreadRepository // destory JobThreadRepository
if (JobThreadRepository.size() > 0) { if (JobThreadRepository.size() > 0) {
for (Map.Entry<Integer, JobThread> item: JobThreadRepository.entrySet()) { for (Map.Entry<Integer, JobThread> item: JobThreadRepository.entrySet()) {
removeJobThread(item.getKey(), "Web容器销毁终止"); removeJobThread(item.getKey(), "web container destroy and kill the job.");
} }
JobThreadRepository.clear(); JobThreadRepository.clear();
} }

@ -181,7 +181,7 @@ public class JobThread extends Thread{
TriggerCallbackThread.pushCallBack(new HandleCallbackParam(triggerParam.getLogId(), triggerParam.getLogDateTim(), executeResult)); TriggerCallbackThread.pushCallBack(new HandleCallbackParam(triggerParam.getLogId(), triggerParam.getLogDateTim(), executeResult));
} else { } else {
// is killed // is killed
ReturnT<String> stopResult = new ReturnT<String>(ReturnT.FAIL_CODE, stopReason + " [业务运行中,被强制终止]"); ReturnT<String> stopResult = new ReturnT<String>(ReturnT.FAIL_CODE, stopReason + " [job runningkilled]");
TriggerCallbackThread.pushCallBack(new HandleCallbackParam(triggerParam.getLogId(), triggerParam.getLogDateTim(), stopResult)); TriggerCallbackThread.pushCallBack(new HandleCallbackParam(triggerParam.getLogId(), triggerParam.getLogDateTim(), stopResult));
} }
} }
@ -193,7 +193,7 @@ public class JobThread extends Thread{
TriggerParam triggerParam = triggerQueue.poll(); TriggerParam triggerParam = triggerQueue.poll();
if (triggerParam!=null) { if (triggerParam!=null) {
// is killed // is killed
ReturnT<String> stopResult = new ReturnT<String>(ReturnT.FAIL_CODE, stopReason + " [任务尚未执行,在调度队列中被终止]"); 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.getLogDateTim(), stopResult));
} }
} }

Loading…
Cancel
Save