Skip to content

Commit

Permalink
ensure an erroring merge task is fully undone on exception but refres…
Browse files Browse the repository at this point in the history
…h the Shepherd for the next task to proceed
  • Loading branch information
holmbergius committed Feb 21, 2025
1 parent a3f9074 commit 38e85ef
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,12 @@ public ScheduledIndividualMerge(MarkedIndividual primaryIndividual,

} catch (Exception e) {
this.setTaskIncomplete();
//rollback this Shepherd to unwind this task and re-open the Shepherd in case it is being reused by a subsequent Task
myShepherd.rollbackDBTransaction();
myShepherd.beginDBTransaction();
e.printStackTrace();
}
}

}

private void mergeIndividuals(MarkedIndividual primaryIndividual,
Expand Down

0 comments on commit 38e85ef

Please sign in to comment.