Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JENKINS-40161] Handle exceptions from StepExecution.onResume #187

Merged
merged 1 commit into from
Dec 16, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,11 @@ public void onSuccess(List<StepExecution> result) {
}
LOGGER.log(Level.FINE, "Will resume {0}", result);
for (StepExecution se : result) {
se.onResume();
try {
se.onResume();
} catch (Throwable x) {
se.getContext().onFailure(x);
dwnusbaum marked this conversation as resolved.
Show resolved Hide resolved
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at this again, it might be better to use se.stop instead, although I'm not sure that it matters for any existing steps besides node. Compare to semi-related changes in jenkinsci/workflow-cps-plugin#780 and jenkinsci/workflow-durable-task-step-plugin#344.

}
}
}

Expand Down