Commit 22fb6b10 by huangfusuper

Merge branches 'developer' and 'test' of https://git.byitgroup.com/liyuan/byit-myth-job into test

parents 13f273d5 fbdcc92d
...@@ -187,9 +187,14 @@ public class ApiFlowServiceImpl implements ApiFlowService { ...@@ -187,9 +187,14 @@ public class ApiFlowServiceImpl implements ApiFlowService {
//设置超时时间,未设置默认5天 //设置超时时间,未设置默认5天
flow.setFlowTimeout(null == pluginFlow.getConfig().getFlowTimeout() ? TimeUnit.DAYS.toMillis(5) : pluginFlow.getConfig().getFlowTimeout()); flow.setFlowTimeout(null == pluginFlow.getConfig().getFlowTimeout() ? TimeUnit.DAYS.toMillis(5) : pluginFlow.getConfig().getFlowTimeout());
Flow oldFlow = flowMapper.getByWorkSpaceAndName(workspaceId, pluginFlow.getName()); Flow oldFlow = flowMapper.getByWorkSpaceAndName(workspaceId, pluginFlow.getName());
String versionName = pluginFlow.getVersionName();
if (StringUtils.isNoneBlank(versionName)) {
FlowVersion byWorkSpaceAndName = flowVersionMapper.getByWorkSpaceAndName(workspaceId, flow.getFlowName(), versionName);
ValidationUtil.isTrueValidation(byWorkSpaceAndName!=null,"该工作流版本已经存在,请联系调度团队!");
}
//判断是否是重发 //判断是否是重发
if ((pluginFlow.isRePublish() && !isInnner) || (isInnner && null != oldFlow)) { if ((pluginFlow.isRePublish() && !isInnner) || (isInnner && null != oldFlow)) {
String versionName = pluginFlow.getVersionName();
flow.setFlowId(oldFlow.getFlowId()); flow.setFlowId(oldFlow.getFlowId());
//当版本号不存在 //当版本号不存在
if (StringUtils.isBlank(versionName)) { if (StringUtils.isBlank(versionName)) {
...@@ -204,7 +209,6 @@ public class ApiFlowServiceImpl implements ApiFlowService { ...@@ -204,7 +209,6 @@ public class ApiFlowServiceImpl implements ApiFlowService {
updateNodeByFlow(pluginFlow.getNodeList(), flow, upFlowName); updateNodeByFlow(pluginFlow.getNodeList(), flow, upFlowName);
} else { } else {
String versionName = pluginFlow.getVersionName();
if (StringUtils.isBlank(versionName)) { if (StringUtils.isBlank(versionName)) {
flow.setVersionName(JobVersionGenUtil.generateVersionName(1)); flow.setVersionName(JobVersionGenUtil.generateVersionName(1));
} else { } else {
......
...@@ -32,7 +32,7 @@ import java.util.Map; ...@@ -32,7 +32,7 @@ import java.util.Map;
*/ */
@Component @Component
@Slf4j @Slf4j
@MythRankOrder(2) @MythRankOrder(3)
public class RpcCallbackInstanceRunTheLifeCycleCallback implements InstanceRunTheLifeCycleCallback { public class RpcCallbackInstanceRunTheLifeCycleCallback implements InstanceRunTheLifeCycleCallback {
@TaskClient(timeout = 60000, callMethodEnum = CallMethodEnum.SYNCHRONIZE) @TaskClient(timeout = 60000, callMethodEnum = CallMethodEnum.SYNCHRONIZE)
......
...@@ -18,7 +18,7 @@ import org.springframework.stereotype.Component; ...@@ -18,7 +18,7 @@ import org.springframework.stereotype.Component;
*/ */
@Component @Component
@Slf4j @Slf4j
@MythRankOrder(1000) @MythRankOrder(4)
public class RunRecordingRunRedisRemoveTheLifeCycleCallback implements InstanceRunTheLifeCycleCallback { public class RunRecordingRunRedisRemoveTheLifeCycleCallback implements InstanceRunTheLifeCycleCallback {
private final StringRedisTemplate stringRedisTemplate; private final StringRedisTemplate stringRedisTemplate;
......
...@@ -24,7 +24,7 @@ import java.util.Map; ...@@ -24,7 +24,7 @@ import java.util.Map;
*/ */
@Component @Component
@Slf4j @Slf4j
@MythRankOrder(5) @MythRankOrder(2)
public class WorkflowCommonParameterAggregation implements InstanceRunTheLifeCycleCallback { public class WorkflowCommonParameterAggregation implements InstanceRunTheLifeCycleCallback {
private final StringRedisTemplate stringRedisTemplate; private final StringRedisTemplate stringRedisTemplate;
......
...@@ -150,7 +150,7 @@ ...@@ -150,7 +150,7 @@
select select
<include refid="Base_Column_List" /> <include refid="Base_Column_List" />
from run_recording from run_recording
where flow_status = '2' and schedule_type != 4 where schedule_type != 4
</select> </select>
<select id="findNoEnd" parameterType="com.byit.dto.FlowConditionDto" resultMap="BaseResultMap"> <select id="findNoEnd" parameterType="com.byit.dto.FlowConditionDto" resultMap="BaseResultMap">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment