Remove the dead code after calling 'handleRunFailure'.
No adjustment of tests needed. Fix #39086
Comment From: BenchmarkingBuffalo
Hi @wilkinsona, thanks for clarifying. I will prepare something.
Comment From: BenchmarkingBuffalo
Hi @wilkinsona, I changed the behavior to the one described in the issue. I also did a small change to the structure of the exception-handling. This was originally due to a hint from sonar, but I actually like it. For me it is easier to understand looking at multiple catch-statements than a wrapped if-statement distinguishing between the exception types. If I did not get it right or you would like me to change something in my solution, just hit me up.
P.S. I was not sure, if handleRunFailure is still a good name, because the other handle... methods are all void, but I did not come up with a better name without creating a long one.
Comment From: philwebb
Thanks very much @BenchmarkingBuffalo. I made one further tweak by pushing the AbandonedRunException logic into the handleRunFailure method.