package com.ruoyi.schedule.domain;

import cn.afterturn.easypoi.excel.annotation.Excel;
import com.mybatisflex.annotation.Column;
import com.mybatisflex.annotation.Id;
import com.mybatisflex.annotation.Table;
import com.ruoyi.common.web.domain.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.Date;

/**
 * 定时任务调度日志 对象
 * @author ruoyi
 */
@EqualsAndHashCode(callSuper = true)
@Data
@Table(value = "sys_job_log")
public class SysJobLog extends BaseEntity {
    private static final long serialVersionUID = 1L;

    @Id
    @Excel(name = "日志编号")
    private Long jobLogId;

    /** 任务名称 */
    @Excel(name = "任务名称")
    private String jobName;

    /** 任务简称 */
    @Excel(name = "任务简称")
    private String jobSimpleName;

    /** 任务组名 */
    @Excel(name = "任务组名")
    private String jobGroup;

    /** 执行表达式 */
    @Excel(name = "执行表达式")
    private String cronExpression;

    /** 执行状态 */
    @Excel(name = "执行状态", replace = { "成功_0", "失败_1" })
    private String status;

    /** 消耗时间（单位：毫秒） */
    @Excel(name = "消耗时间（单位：毫秒）")
    private Long costTime;

    /** 日志信息 */
    @Excel(name = "日志信息")
    private String jobMessage;

    /** 异常信息 */
    @Excel(name = "异常信息")
    private String exceptionInfo;

    @Column(ignore = true)
    private Date startTime;

    @Column(ignore = true)
    private Date endTime;

}
