pnowojski commented on a change in pull request #18336:
URL: https://github.com/apache/flink/pull/18336#discussion_r782836619
##########
File path:
flink-runtime/src/main/java/org/apache/flink/runtime/io/network/partition/PipelinedSubpartitionView.java
##########
@@ -91,7 +91,11 @@ public AvailabilityWithBacklog getAvailabilityAndBacklog(int
numCreditsAvailable
@Override
public Throwable getFailureCause() {
- return parent.getFailureCause();
+ Throwable cause = parent.getFailureCause();
+ if (cause != null) {
+ return new ProducerFailedException(cause);
+ }
+ return null;
Review comment:
Can you document this contract in the
`ResultSubpartitionView#getFailureCause` java doc? That:
> subpartition view can decide whether the failure cause should be reported
to consumer as failure (primary failure) or as cancellation (secondary
failure). Secondary failure can be reported only if producer (upstream task) is
guaranteed to failover. Beware: incorrectly reporting failure cause as primary
failure, can hide the true cause of the failure from the user.
?
--
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]