arjun4084346 commented on code in PR #4008:
URL: https://github.com/apache/gobblin/pull/4008#discussion_r1688415810
##########
gobblin-service/src/main/java/org/apache/gobblin/service/modules/orchestration/proc/DagProcUtils.java:
##########
@@ -193,15 +194,33 @@ public static void sendCancellationEvent(JobExecutionPlan
jobExecutionPlan) {
private static void
sendEnforceJobStartDeadlineDagAction(DagManagementStateStore
dagManagementStateStore, Dag.DagNode<JobExecutionPlan> dagNode)
throws IOException {
- dagManagementStateStore.addJobDagAction(dagNode.getValue().getFlowGroup(),
dagNode.getValue().getFlowName(),
- dagNode.getValue().getFlowExecutionId(),
dagNode.getValue().getJobName(),
+ DagActionStore.DagAction dagAction = new
DagActionStore.DagAction(dagNode.getValue().getFlowGroup(),
+ dagNode.getValue().getFlowName(),
dagNode.getValue().getFlowExecutionId(), dagNode.getValue().getJobName(),
DagActionStore.DagActionType.ENFORCE_JOB_START_DEADLINE);
+ try {
+ dagManagementStateStore.addDagAction(dagAction);
+ } catch (IOException e) {
+ if (e.getCause() != null && e.getCause() instanceof
SQLIntegrityConstraintViolationException) {
+ dagManagementStateStore.deleteDagAction(dagAction);
Review Comment:
The intention is to have a deadline dag proc with new deadline time.
##########
gobblin-service/src/main/java/org/apache/gobblin/service/modules/orchestration/proc/DagProcUtils.java:
##########
@@ -193,15 +194,33 @@ public static void sendCancellationEvent(JobExecutionPlan
jobExecutionPlan) {
private static void
sendEnforceJobStartDeadlineDagAction(DagManagementStateStore
dagManagementStateStore, Dag.DagNode<JobExecutionPlan> dagNode)
throws IOException {
- dagManagementStateStore.addJobDagAction(dagNode.getValue().getFlowGroup(),
dagNode.getValue().getFlowName(),
- dagNode.getValue().getFlowExecutionId(),
dagNode.getValue().getJobName(),
+ DagActionStore.DagAction dagAction = new
DagActionStore.DagAction(dagNode.getValue().getFlowGroup(),
+ dagNode.getValue().getFlowName(),
dagNode.getValue().getFlowExecutionId(), dagNode.getValue().getJobName(),
DagActionStore.DagActionType.ENFORCE_JOB_START_DEADLINE);
+ try {
+ dagManagementStateStore.addDagAction(dagAction);
+ } catch (IOException e) {
+ if (e.getCause() != null && e.getCause() instanceof
SQLIntegrityConstraintViolationException) {
+ dagManagementStateStore.deleteDagAction(dagAction);
Review Comment:
The intention is to have a deadline dag proc with the new deadline time.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]