定时任务导出增加并发执行字段
parent
e34b4ea63d
commit
47f5d7a7b7
|
@ -11,7 +11,6 @@ import org.apache.commons.lang3.exception.ExceptionUtils;
|
||||||
*/
|
*/
|
||||||
public class ExceptionUtil
|
public class ExceptionUtil
|
||||||
{
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取exception的详细错误信息。
|
* 获取exception的详细错误信息。
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -123,7 +123,7 @@ public class SysJobController extends BaseController
|
||||||
@RequiresPermissions("monitor:job:add")
|
@RequiresPermissions("monitor:job:add")
|
||||||
@PostMapping("/add")
|
@PostMapping("/add")
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public AjaxResult addSave(SysJob job) throws Exception
|
public AjaxResult addSave(SysJob job) throws SchedulerException, TaskException
|
||||||
{
|
{
|
||||||
return toAjax(jobService.insertJobCron(job));
|
return toAjax(jobService.insertJobCron(job));
|
||||||
}
|
}
|
||||||
|
|
|
@ -48,6 +48,7 @@ public class SysJob extends BaseEntity implements Serializable
|
||||||
private String misfirePolicy = ScheduleConstants.MISFIRE_DEFAULT;
|
private String misfirePolicy = ScheduleConstants.MISFIRE_DEFAULT;
|
||||||
|
|
||||||
/** 是否并发执行(0允许 1禁止) */
|
/** 是否并发执行(0允许 1禁止) */
|
||||||
|
@Excel(name = "并发执行", readConverterExp = "0=允许,1=禁止")
|
||||||
private String concurrent;
|
private String concurrent;
|
||||||
|
|
||||||
/** 任务状态(0正常 1暂停) */
|
/** 任务状态(0正常 1暂停) */
|
||||||
|
|
|
@ -3,7 +3,6 @@ package com.ruoyi.quartz.domain;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
|
||||||
import com.ruoyi.common.annotation.Excel;
|
import com.ruoyi.common.annotation.Excel;
|
||||||
import com.ruoyi.common.core.domain.BaseEntity;
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
|
||||||
|
@ -49,11 +48,9 @@ public class SysJobLog extends BaseEntity
|
||||||
private String exceptionInfo;
|
private String exceptionInfo;
|
||||||
|
|
||||||
/** 开始时间 */
|
/** 开始时间 */
|
||||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
|
||||||
private Date startTime;
|
private Date startTime;
|
||||||
|
|
||||||
/** 结束时间 */
|
/** 结束时间 */
|
||||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
|
||||||
private Date endTime;
|
private Date endTime;
|
||||||
|
|
||||||
public Long getJobLogId()
|
public Long getJobLogId()
|
||||||
|
|
|
@ -33,11 +33,6 @@ public class JobInvokeUtil
|
||||||
* @param bean 目标对象
|
* @param bean 目标对象
|
||||||
* @param methodName 方法名称
|
* @param methodName 方法名称
|
||||||
* @param methodParams 方法参数
|
* @param methodParams 方法参数
|
||||||
* @throws InvocationTargetException
|
|
||||||
* @throws SecurityException
|
|
||||||
* @throws NoSuchMethodException
|
|
||||||
* @throws IllegalArgumentException
|
|
||||||
* @throws IllegalAccessException
|
|
||||||
*/
|
*/
|
||||||
private static void invokeSpringBean(Object bean, String methodName, String methodParams)
|
private static void invokeSpringBean(Object bean, String methodName, String methodParams)
|
||||||
throws NoSuchMethodException, SecurityException, IllegalAccessException, IllegalArgumentException,
|
throws NoSuchMethodException, SecurityException, IllegalAccessException, IllegalArgumentException,
|
||||||
|
|
|
@ -406,7 +406,7 @@ create table sys_oper_log (
|
||||||
oper_url varchar(255) default '' comment '请求URL',
|
oper_url varchar(255) default '' comment '请求URL',
|
||||||
oper_ip varchar(50) default '' comment '主机地址',
|
oper_ip varchar(50) default '' comment '主机地址',
|
||||||
oper_location varchar(255) default '' comment '操作地点',
|
oper_location varchar(255) default '' comment '操作地点',
|
||||||
oper_param varchar(255) default '' comment '请求参数',
|
oper_param varchar(2000) default '' comment '请求参数',
|
||||||
status int(1) default 0 comment '操作状态(0正常 1异常)',
|
status int(1) default 0 comment '操作状态(0正常 1异常)',
|
||||||
error_msg varchar(2000) default '' comment '错误消息',
|
error_msg varchar(2000) default '' comment '错误消息',
|
||||||
oper_time datetime comment '操作时间',
|
oper_time datetime comment '操作时间',
|
||||||
|
@ -568,7 +568,7 @@ create table sys_job (
|
||||||
method_params varchar(50) default null comment '方法参数',
|
method_params varchar(50) default null comment '方法参数',
|
||||||
cron_expression varchar(255) default '' comment 'cron执行表达式',
|
cron_expression varchar(255) default '' comment 'cron执行表达式',
|
||||||
misfire_policy varchar(20) default '3' comment '计划执行错误策略(1立即执行 2执行一次 3放弃执行)',
|
misfire_policy varchar(20) default '3' comment '计划执行错误策略(1立即执行 2执行一次 3放弃执行)',
|
||||||
concurrent char default '1' comment '是否并发执行(0允许 1禁止)',
|
concurrent char(1) default '1' comment '是否并发执行(0允许 1禁止)',
|
||||||
status char(1) default '0' comment '状态(0正常 1暂停)',
|
status char(1) default '0' comment '状态(0正常 1暂停)',
|
||||||
create_by varchar(64) default '' comment '创建者',
|
create_by varchar(64) default '' comment '创建者',
|
||||||
create_time datetime comment '创建时间',
|
create_time datetime comment '创建时间',
|
||||||
|
|
Loading…
Reference in New Issue