akalash commented on a change in pull request #17701:
URL: https://github.com/apache/flink/pull/17701#discussion_r749439863
##########
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:
Yes, it is true. But according to `TODO` above it wasn't clear why we
used `Throwable` at all. I personally think that it is not a problem that in
case of unexpected throwable we lost other exceptions because this throwable
will be the much more important. But of course, we can discuss it
--
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]