Skip to content

Commit 8deecbf

Browse files
committed
ExceptionCause is actually still used #124 (comment)
1 parent 1c57e2f commit 8deecbf

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

src/main/java/org/jenkinsci/plugins/workflow/steps/ExceptionCause.java

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,14 @@
44

55
import java.io.Serializable;
66

7-
@Deprecated
7+
/**
8+
* {@link CauseOfInterruption} that captures random {@link Throwable},
9+
* which is used when the cancellation is in response to some failures.
10+
*
11+
* TODO: move this to core
12+
* TODO: better summary.jelly
13+
* @author Kohsuke Kawaguchi
14+
*/
815
class ExceptionCause extends CauseOfInterruption implements Serializable {
916
private final Throwable t;
1017

src/main/java/org/jenkinsci/plugins/workflow/steps/SynchronousStepExecution.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ public void stop(Throwable cause) throws Exception {
5151
Thread e = executing; // capture
5252
if (e!=null) {
5353
if (e instanceof Executor) {
54+
// TODO if cause instanceof FlowInterruptedException, unpack result & causes
5455
((Executor) e).interrupt(ABORTED, new ExceptionCause(cause));
5556
} else {
5657
e.interrupt();

0 commit comments

Comments
 (0)