dawidwys commented on a change in pull request #17701:
URL: https://github.com/apache/flink/pull/17701#discussion_r754886188
##########
File path:
flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/StreamTask.java
##########
@@ -989,19 +1006,6 @@ private void releaseOutputResources() throws Exception {
}
}
- private Exception runAndSuppressThrowable(
- ThrowingRunnable<?> runnable, @Nullable Exception
originalException) {
- try {
- runnable.run();
- } catch (Throwable t) {
- // TODO: investigate why Throwable instead of Exception is used
here.
- Exception e = t instanceof Exception ? (Exception) t : new
Exception(t);
Review comment:
One more point to the discussion, which actually makes me prefer keeping
the old behaviour.
In `TaskCanceler` we catch `Throwable` and rethrow it only if it is one of
`InternalError`, `UnknownError`, `ThreadDeath` all other are ignored. If we
ignore an error we should have a proper resource cleaning for such an error and
thus we should not skip resource cleaning for `Throwables`, imo.
--
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]