pull/22/MERGE
xueli.xue 4 years ago
parent 4a8e0f10f9
commit 20a1e1ee49

@ -2086,7 +2086,7 @@ data: post-data
- 20、执行器注册组件优化注册逻辑调整为异步方式提高注册性能
- 21、调度过期策略调度中心错误调度时间的补偿处理策略包括忽略、立即补偿触发一次等
- 22、触发策略强化除了常规Cron、API、父子任务触发方式外新增提供 "固定间隔触发、固定延时触发" 两种新触发方式;
- 23、任务调度生命周期重构调度schedule、触发(trigger)、执行handle、回调(callback)、后处理posthandle
- 23、任务调度生命周期重构调度schedule、触发(trigger)、执行handle、回调(callback)、结束complete
- 24、执行器鉴权校验执行器启动时主动校验accessToken为空则主动Warn告警已规划安全强化AccessToken动态生成、动态启停等
### 7.32 版本 v2.3.0 Release Notes[规划中]

@ -1,7 +1,7 @@
package com.xxl.job.admin.controller;
import com.xxl.job.admin.core.exception.XxlJobException;
import com.xxl.job.admin.core.handle.XxlJobPostHandleHelper;
import com.xxl.job.admin.core.complete.XxlJobCompleter;
import com.xxl.job.admin.core.model.XxlJobGroup;
import com.xxl.job.admin.core.model.XxlJobInfo;
import com.xxl.job.admin.core.model.XxlJobLog;
@ -184,7 +184,7 @@ public class JobLogController {
log.setHandleCode(ReturnT.FAIL_CODE);
log.setHandleMsg( I18nUtil.getString("joblog_kill_log_byman")+":" + (runResult.getMsg()!=null?runResult.getMsg():""));
log.setHandleTime(new Date());
XxlJobPostHandleHelper.updateHandleInfoAndFinish(log);
XxlJobCompleter.updateHandleInfoAndFinish(log);
return new ReturnT<String>(runResult.getMsg());
} else {
return new ReturnT<String>(500, runResult.getMsg());

@ -1,4 +1,4 @@
package com.xxl.job.admin.core.handle;
package com.xxl.job.admin.core.complete;
import com.xxl.job.admin.core.conf.XxlJobAdminConfig;
import com.xxl.job.admin.core.model.XxlJobInfo;
@ -16,8 +16,8 @@ import java.text.MessageFormat;
/**
* @author xuxueli 2020-10-30 20:43:10
*/
public class XxlJobPostHandleHelper {
private static Logger logger = LoggerFactory.getLogger(XxlJobPostHandleHelper.class);
public class XxlJobCompleter {
private static Logger logger = LoggerFactory.getLogger(XxlJobCompleter.class);
/**
* common fresh handle entrance (limit only once)

@ -34,7 +34,7 @@ public class XxlJobScheduler {
JobFailMonitorHelper.getInstance().start();
// admin lose-monitor run ( depend on JobTriggerPoolHelper )
JobLogHelper.getInstance().start();
JobCompleteHelper.getInstance().start();
// admin log report start
JobLogReportHelper.getInstance().start();
@ -55,7 +55,7 @@ public class XxlJobScheduler {
JobLogReportHelper.getInstance().toStop();
// admin lose-monitor stop
JobLogHelper.getInstance().toStop();
JobCompleteHelper.getInstance().toStop();
// admin fail-monitor stop
JobFailMonitorHelper.getInstance().toStop();

@ -1,7 +1,7 @@
package com.xxl.job.admin.core.thread;
import com.xxl.job.admin.core.conf.XxlJobAdminConfig;
import com.xxl.job.admin.core.handle.XxlJobPostHandleHelper;
import com.xxl.job.admin.core.complete.XxlJobCompleter;
import com.xxl.job.admin.core.model.XxlJobLog;
import com.xxl.job.admin.core.util.I18nUtil;
import com.xxl.job.core.biz.model.HandleCallbackParam;
@ -20,11 +20,11 @@ import java.util.concurrent.*;
*
* @author xuxueli 2015-9-1 18:05:56
*/
public class JobLogHelper {
private static Logger logger = LoggerFactory.getLogger(JobLogHelper.class);
public class JobCompleteHelper {
private static Logger logger = LoggerFactory.getLogger(JobCompleteHelper.class);
private static JobLogHelper instance = new JobLogHelper();
public static JobLogHelper getInstance(){
private static JobCompleteHelper instance = new JobCompleteHelper();
public static JobCompleteHelper getInstance(){
return instance;
}
@ -89,7 +89,7 @@ public class JobLogHelper {
jobLog.setHandleCode(ReturnT.FAIL_CODE);
jobLog.setHandleMsg( I18nUtil.getString("joblog_lost_fail") );
XxlJobPostHandleHelper.updateHandleInfoAndFinish(jobLog);
XxlJobCompleter.updateHandleInfoAndFinish(jobLog);
}
}
@ -175,7 +175,7 @@ public class JobLogHelper {
log.setHandleTime(new Date());
log.setHandleCode(handleCallbackParam.getExecuteResult().getCode());
log.setHandleMsg(handleMsg.toString());
XxlJobPostHandleHelper.updateHandleInfoAndFinish(log);
XxlJobCompleter.updateHandleInfoAndFinish(log);
return ReturnT.SUCCESS;
}

@ -1,6 +1,6 @@
package com.xxl.job.admin.service.impl;
import com.xxl.job.admin.core.thread.JobLogHelper;
import com.xxl.job.admin.core.thread.JobCompleteHelper;
import com.xxl.job.admin.core.thread.JobRegistryHelper;
import com.xxl.job.core.biz.AdminBiz;
import com.xxl.job.core.biz.model.HandleCallbackParam;
@ -19,7 +19,7 @@ public class AdminBizImpl implements AdminBiz {
@Override
public ReturnT<String> callback(List<HandleCallbackParam> callbackParamList) {
return JobLogHelper.getInstance().callback(callbackParamList);
return JobCompleteHelper.getInstance().callback(callbackParamList);
}
@Override

Loading…
Cancel
Save