|
|
@ -14,13 +14,9 @@ |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* See the License for the specific language governing permissions and |
|
|
|
* limitations under the License. |
|
|
|
* limitations under the License. |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
|
|
|
|
|
|
|
|
package org.apache.dolphinscheduler.dao.entity; |
|
|
|
package org.apache.dolphinscheduler.dao.entity; |
|
|
|
|
|
|
|
|
|
|
|
import com.baomidou.mybatisplus.annotation.IdType; |
|
|
|
|
|
|
|
import com.baomidou.mybatisplus.annotation.TableField; |
|
|
|
|
|
|
|
import com.baomidou.mybatisplus.annotation.TableId; |
|
|
|
|
|
|
|
import com.baomidou.mybatisplus.annotation.TableName; |
|
|
|
|
|
|
|
import com.fasterxml.jackson.annotation.JsonFormat; |
|
|
|
|
|
|
|
import org.apache.dolphinscheduler.common.enums.FailureStrategy; |
|
|
|
import org.apache.dolphinscheduler.common.enums.FailureStrategy; |
|
|
|
import org.apache.dolphinscheduler.common.enums.Priority; |
|
|
|
import org.apache.dolphinscheduler.common.enums.Priority; |
|
|
|
import org.apache.dolphinscheduler.common.enums.ReleaseState; |
|
|
|
import org.apache.dolphinscheduler.common.enums.ReleaseState; |
|
|
@ -28,6 +24,12 @@ import org.apache.dolphinscheduler.common.enums.WarningType; |
|
|
|
|
|
|
|
|
|
|
|
import java.util.Date; |
|
|
|
import java.util.Date; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import com.baomidou.mybatisplus.annotation.IdType; |
|
|
|
|
|
|
|
import com.baomidou.mybatisplus.annotation.TableField; |
|
|
|
|
|
|
|
import com.baomidou.mybatisplus.annotation.TableId; |
|
|
|
|
|
|
|
import com.baomidou.mybatisplus.annotation.TableName; |
|
|
|
|
|
|
|
import com.fasterxml.jackson.annotation.JsonFormat; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* schedule |
|
|
|
* schedule |
|
|
|
* |
|
|
|
* |
|
|
@ -35,278 +37,285 @@ import java.util.Date; |
|
|
|
@TableName("t_ds_schedules") |
|
|
|
@TableName("t_ds_schedules") |
|
|
|
public class Schedule { |
|
|
|
public class Schedule { |
|
|
|
|
|
|
|
|
|
|
|
@TableId(value="id", type=IdType.AUTO) |
|
|
|
@TableId(value = "id", type = IdType.AUTO) |
|
|
|
private int id; |
|
|
|
private int id; |
|
|
|
/** |
|
|
|
/** |
|
|
|
* process definition id |
|
|
|
* process definition id |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
private int processDefinitionId; |
|
|
|
private int processDefinitionId; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* process definition name |
|
|
|
* process definition name |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@TableField(exist = false) |
|
|
|
@TableField(exist = false) |
|
|
|
private String processDefinitionName; |
|
|
|
private String processDefinitionName; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* project name |
|
|
|
* project name |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@TableField(exist = false) |
|
|
|
@TableField(exist = false) |
|
|
|
private String projectName; |
|
|
|
private String projectName; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* schedule description |
|
|
|
* schedule description |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@TableField(exist = false) |
|
|
|
@TableField(exist = false) |
|
|
|
private String definitionDescription; |
|
|
|
private String definitionDescription; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* schedule start time |
|
|
|
* schedule start time |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") |
|
|
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8") |
|
|
|
private Date startTime; |
|
|
|
private Date startTime; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* schedule end time |
|
|
|
* schedule end time |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") |
|
|
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8") |
|
|
|
private Date endTime; |
|
|
|
private Date endTime; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* crontab expression |
|
|
|
* timezoneId |
|
|
|
*/ |
|
|
|
* <p>see {@link java.util.TimeZone#getTimeZone(String)} |
|
|
|
private String crontab; |
|
|
|
*/ |
|
|
|
|
|
|
|
private String timezoneId; |
|
|
|
/** |
|
|
|
|
|
|
|
* failure strategy |
|
|
|
/** |
|
|
|
*/ |
|
|
|
* crontab expression |
|
|
|
private FailureStrategy failureStrategy; |
|
|
|
*/ |
|
|
|
|
|
|
|
private String crontab; |
|
|
|
/** |
|
|
|
|
|
|
|
* warning type |
|
|
|
/** |
|
|
|
*/ |
|
|
|
* failure strategy |
|
|
|
private WarningType warningType; |
|
|
|
*/ |
|
|
|
|
|
|
|
private FailureStrategy failureStrategy; |
|
|
|
/** |
|
|
|
|
|
|
|
* create time |
|
|
|
/** |
|
|
|
*/ |
|
|
|
* warning type |
|
|
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") |
|
|
|
*/ |
|
|
|
private Date createTime; |
|
|
|
private WarningType warningType; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* update time |
|
|
|
* create time |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") |
|
|
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8") |
|
|
|
private Date updateTime; |
|
|
|
private Date createTime; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* created user id |
|
|
|
* update time |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
private int userId; |
|
|
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8") |
|
|
|
|
|
|
|
private Date updateTime; |
|
|
|
/** |
|
|
|
|
|
|
|
* created user name |
|
|
|
/** |
|
|
|
*/ |
|
|
|
* created user id |
|
|
|
@TableField(exist = false) |
|
|
|
*/ |
|
|
|
private String userName; |
|
|
|
private int userId; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* release state |
|
|
|
* created user name |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
private ReleaseState releaseState; |
|
|
|
@TableField(exist = false) |
|
|
|
|
|
|
|
private String userName; |
|
|
|
/** |
|
|
|
|
|
|
|
* warning group id |
|
|
|
/** |
|
|
|
*/ |
|
|
|
* release state |
|
|
|
private int warningGroupId; |
|
|
|
*/ |
|
|
|
|
|
|
|
private ReleaseState releaseState; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* process instance priority |
|
|
|
* warning group id |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
private Priority processInstancePriority; |
|
|
|
private int warningGroupId; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
|
|
* worker group |
|
|
|
/** |
|
|
|
*/ |
|
|
|
* process instance priority |
|
|
|
private String workerGroup; |
|
|
|
*/ |
|
|
|
|
|
|
|
private Priority processInstancePriority; |
|
|
|
public int getWarningGroupId() { |
|
|
|
|
|
|
|
return warningGroupId; |
|
|
|
/** |
|
|
|
} |
|
|
|
* worker group |
|
|
|
|
|
|
|
*/ |
|
|
|
public void setWarningGroupId(int warningGroupId) { |
|
|
|
private String workerGroup; |
|
|
|
this.warningGroupId = warningGroupId; |
|
|
|
|
|
|
|
} |
|
|
|
public int getWarningGroupId() { |
|
|
|
|
|
|
|
return warningGroupId; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public Schedule() { |
|
|
|
public void setWarningGroupId(int warningGroupId) { |
|
|
|
} |
|
|
|
this.warningGroupId = warningGroupId; |
|
|
|
|
|
|
|
} |
|
|
|
public String getProjectName() { |
|
|
|
|
|
|
|
return projectName; |
|
|
|
public Schedule() { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public void setProjectName(String projectName) { |
|
|
|
public String getProjectName() { |
|
|
|
this.projectName = projectName; |
|
|
|
return projectName; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setProjectName(String projectName) { |
|
|
|
|
|
|
|
this.projectName = projectName; |
|
|
|
public Date getStartTime() { |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
return startTime; |
|
|
|
public Date getStartTime() { |
|
|
|
} |
|
|
|
return startTime; |
|
|
|
|
|
|
|
} |
|
|
|
public void setStartTime(Date startTime) { |
|
|
|
|
|
|
|
this.startTime = startTime; |
|
|
|
public void setStartTime(Date startTime) { |
|
|
|
} |
|
|
|
this.startTime = startTime; |
|
|
|
|
|
|
|
} |
|
|
|
public Date getEndTime() { |
|
|
|
|
|
|
|
return endTime; |
|
|
|
public Date getEndTime() { |
|
|
|
} |
|
|
|
return endTime; |
|
|
|
|
|
|
|
} |
|
|
|
public void setEndTime(Date endTime) { |
|
|
|
|
|
|
|
this.endTime = endTime; |
|
|
|
public void setEndTime(Date endTime) { |
|
|
|
} |
|
|
|
this.endTime = endTime; |
|
|
|
|
|
|
|
} |
|
|
|
public String getCrontab() { |
|
|
|
|
|
|
|
return crontab; |
|
|
|
public String getTimezoneId() { |
|
|
|
} |
|
|
|
return timezoneId; |
|
|
|
|
|
|
|
} |
|
|
|
public void setCrontab(String crontab) { |
|
|
|
|
|
|
|
this.crontab = crontab; |
|
|
|
public void setTimezoneId(String timezoneId) { |
|
|
|
} |
|
|
|
this.timezoneId = timezoneId; |
|
|
|
|
|
|
|
} |
|
|
|
public FailureStrategy getFailureStrategy() { |
|
|
|
|
|
|
|
return failureStrategy; |
|
|
|
public String getCrontab() { |
|
|
|
} |
|
|
|
return crontab; |
|
|
|
|
|
|
|
} |
|
|
|
public void setFailureStrategy(FailureStrategy failureStrategy) { |
|
|
|
|
|
|
|
this.failureStrategy = failureStrategy; |
|
|
|
public void setCrontab(String crontab) { |
|
|
|
} |
|
|
|
this.crontab = crontab; |
|
|
|
|
|
|
|
} |
|
|
|
public WarningType getWarningType() { |
|
|
|
|
|
|
|
return warningType; |
|
|
|
public FailureStrategy getFailureStrategy() { |
|
|
|
} |
|
|
|
return failureStrategy; |
|
|
|
|
|
|
|
} |
|
|
|
public void setWarningType(WarningType warningType) { |
|
|
|
|
|
|
|
this.warningType = warningType; |
|
|
|
public void setFailureStrategy(FailureStrategy failureStrategy) { |
|
|
|
} |
|
|
|
this.failureStrategy = failureStrategy; |
|
|
|
|
|
|
|
} |
|
|
|
public Date getCreateTime() { |
|
|
|
|
|
|
|
return createTime; |
|
|
|
public WarningType getWarningType() { |
|
|
|
} |
|
|
|
return warningType; |
|
|
|
|
|
|
|
} |
|
|
|
public void setCreateTime(Date createTime) { |
|
|
|
|
|
|
|
this.createTime = createTime; |
|
|
|
public void setWarningType(WarningType warningType) { |
|
|
|
} |
|
|
|
this.warningType = warningType; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public ReleaseState getReleaseState() { |
|
|
|
public Date getCreateTime() { |
|
|
|
return releaseState; |
|
|
|
return createTime; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public void setReleaseState(ReleaseState releaseState) { |
|
|
|
public void setCreateTime(Date createTime) { |
|
|
|
this.releaseState = releaseState; |
|
|
|
this.createTime = createTime; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public ReleaseState getReleaseState() { |
|
|
|
|
|
|
|
return releaseState; |
|
|
|
public int getProcessDefinitionId() { |
|
|
|
} |
|
|
|
return processDefinitionId; |
|
|
|
|
|
|
|
} |
|
|
|
public void setReleaseState(ReleaseState releaseState) { |
|
|
|
|
|
|
|
this.releaseState = releaseState; |
|
|
|
public void setProcessDefinitionId(int processDefinitionId) { |
|
|
|
} |
|
|
|
this.processDefinitionId = processDefinitionId; |
|
|
|
|
|
|
|
} |
|
|
|
public int getProcessDefinitionId() { |
|
|
|
|
|
|
|
return processDefinitionId; |
|
|
|
public String getProcessDefinitionName() { |
|
|
|
} |
|
|
|
return processDefinitionName; |
|
|
|
|
|
|
|
} |
|
|
|
public void setProcessDefinitionId(int processDefinitionId) { |
|
|
|
|
|
|
|
this.processDefinitionId = processDefinitionId; |
|
|
|
public void setProcessDefinitionName(String processDefinitionName) { |
|
|
|
} |
|
|
|
this.processDefinitionName = processDefinitionName; |
|
|
|
|
|
|
|
} |
|
|
|
public String getProcessDefinitionName() { |
|
|
|
|
|
|
|
return processDefinitionName; |
|
|
|
public Date getUpdateTime() { |
|
|
|
} |
|
|
|
return updateTime; |
|
|
|
|
|
|
|
} |
|
|
|
public void setProcessDefinitionName(String processDefinitionName) { |
|
|
|
|
|
|
|
this.processDefinitionName = processDefinitionName; |
|
|
|
public void setUpdateTime(Date updateTime) { |
|
|
|
} |
|
|
|
this.updateTime = updateTime; |
|
|
|
|
|
|
|
} |
|
|
|
public Date getUpdateTime() { |
|
|
|
|
|
|
|
return updateTime; |
|
|
|
public int getUserId() { |
|
|
|
} |
|
|
|
return userId; |
|
|
|
|
|
|
|
} |
|
|
|
public void setUpdateTime(Date updateTime) { |
|
|
|
|
|
|
|
this.updateTime = updateTime; |
|
|
|
public void setUserId(int userId) { |
|
|
|
} |
|
|
|
this.userId = userId; |
|
|
|
|
|
|
|
} |
|
|
|
public int getUserId() { |
|
|
|
|
|
|
|
return userId; |
|
|
|
public String getUserName() { |
|
|
|
} |
|
|
|
return userName; |
|
|
|
|
|
|
|
} |
|
|
|
public void setUserId(int userId) { |
|
|
|
|
|
|
|
this.userId = userId; |
|
|
|
public void setUserName(String userName) { |
|
|
|
} |
|
|
|
this.userName = userName; |
|
|
|
|
|
|
|
} |
|
|
|
public String getUserName() { |
|
|
|
|
|
|
|
return userName; |
|
|
|
public int getId() { |
|
|
|
} |
|
|
|
return id; |
|
|
|
|
|
|
|
} |
|
|
|
public void setUserName(String userName) { |
|
|
|
|
|
|
|
this.userName = userName; |
|
|
|
public void setId(int id) { |
|
|
|
} |
|
|
|
this.id = id; |
|
|
|
|
|
|
|
} |
|
|
|
public int getId() { |
|
|
|
|
|
|
|
return id; |
|
|
|
public Priority getProcessInstancePriority() { |
|
|
|
} |
|
|
|
return processInstancePriority; |
|
|
|
|
|
|
|
} |
|
|
|
public void setId(int id) { |
|
|
|
|
|
|
|
this.id = id; |
|
|
|
public void setProcessInstancePriority(Priority processInstancePriority) { |
|
|
|
} |
|
|
|
this.processInstancePriority = processInstancePriority; |
|
|
|
|
|
|
|
} |
|
|
|
public Priority getProcessInstancePriority() { |
|
|
|
|
|
|
|
return processInstancePriority; |
|
|
|
public String getWorkerGroup() { |
|
|
|
} |
|
|
|
return workerGroup; |
|
|
|
|
|
|
|
} |
|
|
|
public void setProcessInstancePriority(Priority processInstancePriority) { |
|
|
|
|
|
|
|
this.processInstancePriority = processInstancePriority; |
|
|
|
public void setWorkerGroup(String workerGroup) { |
|
|
|
} |
|
|
|
this.workerGroup = workerGroup; |
|
|
|
|
|
|
|
} |
|
|
|
public String getWorkerGroup() { |
|
|
|
|
|
|
|
return workerGroup; |
|
|
|
@Override |
|
|
|
} |
|
|
|
public String toString() { |
|
|
|
|
|
|
|
return "Schedule{" + |
|
|
|
public void setWorkerGroup(String workerGroup) { |
|
|
|
"id=" + id + |
|
|
|
this.workerGroup = workerGroup; |
|
|
|
", processDefinitionId=" + processDefinitionId + |
|
|
|
} |
|
|
|
", processDefinitionName='" + processDefinitionName + '\'' + |
|
|
|
|
|
|
|
", projectName='" + projectName + '\'' + |
|
|
|
@Override |
|
|
|
", description='" + definitionDescription + '\'' + |
|
|
|
public String toString() { |
|
|
|
", startTime=" + startTime + |
|
|
|
return "Schedule{" |
|
|
|
", endTime=" + endTime + |
|
|
|
+ "id=" + id |
|
|
|
", crontab='" + crontab + '\'' + |
|
|
|
+ ", processDefinitionId=" + processDefinitionId |
|
|
|
", failureStrategy=" + failureStrategy + |
|
|
|
+ ", processDefinitionName='" + processDefinitionName + '\'' |
|
|
|
", warningType=" + warningType + |
|
|
|
+ ", projectName='" + projectName + '\'' |
|
|
|
", createTime=" + createTime + |
|
|
|
+ ", description='" + definitionDescription + '\'' |
|
|
|
", updateTime=" + updateTime + |
|
|
|
+ ", startTime=" + startTime |
|
|
|
", userId=" + userId + |
|
|
|
+ ", endTime=" + endTime |
|
|
|
", userName='" + userName + '\'' + |
|
|
|
+ ", timezoneId='" + timezoneId + +'\'' |
|
|
|
", releaseState=" + releaseState + |
|
|
|
+ ", crontab='" + crontab + '\'' |
|
|
|
", warningGroupId=" + warningGroupId + |
|
|
|
+ ", failureStrategy=" + failureStrategy |
|
|
|
", processInstancePriority=" + processInstancePriority + |
|
|
|
+ ", warningType=" + warningType |
|
|
|
", workerGroup='" + workerGroup + '\'' + |
|
|
|
+ ", createTime=" + createTime |
|
|
|
'}'; |
|
|
|
+ ", updateTime=" + updateTime |
|
|
|
} |
|
|
|
+ ", userId=" + userId |
|
|
|
|
|
|
|
+ ", userName='" + userName + '\'' |
|
|
|
public String getDefinitionDescription() { |
|
|
|
+ ", releaseState=" + releaseState |
|
|
|
return definitionDescription; |
|
|
|
+ ", warningGroupId=" + warningGroupId |
|
|
|
} |
|
|
|
+ ", processInstancePriority=" + processInstancePriority |
|
|
|
|
|
|
|
+ ", workerGroup='" + workerGroup + '\'' |
|
|
|
public void setDefinitionDescription(String definitionDescription) { |
|
|
|
+ '}'; |
|
|
|
this.definitionDescription = definitionDescription; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public String getDefinitionDescription() { |
|
|
|
|
|
|
|
return definitionDescription; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setDefinitionDescription(String definitionDescription) { |
|
|
|
|
|
|
|
this.definitionDescription = definitionDescription; |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|