事务修改
This commit is contained in:
parent
d083c2be99
commit
898de4e49a
@ -152,7 +152,8 @@ public class DefaultRunContextManager implements RunContextManager {
|
|||||||
}
|
}
|
||||||
pipelineRunContext.changeContextStateAndChild(stateEnum);
|
pipelineRunContext.changeContextStateAndChild(stateEnum);
|
||||||
}
|
}
|
||||||
@Transactional(rollbackFor = Exception.class)
|
// 记录日志需要新事物,成功或失败不影响流水线执行
|
||||||
|
@Transactional(rollbackFor = Exception.class,propagation = Propagation.REQUIRES_NEW)
|
||||||
public void toHistory(String pipelineId){
|
public void toHistory(String pipelineId){
|
||||||
log.info("========================开始入库");
|
log.info("========================开始入库");
|
||||||
BaseRunContext context = getContext(pipelineId);
|
BaseRunContext context = getContext(pipelineId);
|
||||||
|
@ -118,7 +118,7 @@ public class MemoryLogManager implements LoggerManager {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@Transactional
|
@Transactional(rollbackFor = Exception.class)
|
||||||
public void flushMemory(List<TaskRunContext> taskContextList){
|
public void flushMemory(List<TaskRunContext> taskContextList){
|
||||||
log.info("流水线日志开始入库");
|
log.info("流水线日志开始入库");
|
||||||
List<PipTaskLog> insertList = new ArrayList<>();
|
List<PipTaskLog> insertList = new ArrayList<>();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user