[
https://issues.apache.org/jira/browse/FLINK-12474?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16839198#comment-16839198
]
Piotr Nowojski commented on FLINK-12474:
----------------------------------------
> But if the `UnionInputGate` is waiting for buffer, task thread is still
>stucking in wait when `SingleInputGate` is closed until cancel timeout.
Did you mean that while {{UnionInputGate}} is waiting for
{{inputGatesWithData.wait()}} it is not being notified/woken up? Either way I
would say this is a low priority issue, since now I'm working on making
{{CheckpointBarrierHandler}} non blocking and I would like to deprecate
blocking calls on the {{InputGate}}.
Secondly, I think there is somewhere a code that will interrupt a thread during
a cancellation. So any {{.wait()}} should be unblocked by this.
> UnionInputGate should be notified when closing SingleInputGate by canceler
> thread
> ---------------------------------------------------------------------------------
>
> Key: FLINK-12474
> URL: https://issues.apache.org/jira/browse/FLINK-12474
> Project: Flink
> Issue Type: Improvement
> Components: Runtime / Network
> Reporter: zhijiang
> Priority: Minor
>
> If task is being canceled, the `SingleInputGate` would be closed by canceler
> thread. If the `SingleInputGate` is waiting for buffer,
> `inputChannelWithData` would be notified to wake task thread to exit early.
> But if the `UnionInputGate` is waiting for buffer, task thread is still
> stucking in wait when `SingleInputGate` is closed until cancel timeout.
> To make task exit early in this case, we could make `SingleInputGate` further
> notify `UnionInputGate` after it is closed, then it could also wake task
> thread to exit during canceling.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)