[ https://issues.apache.org/jira/browse/FLINK-13638?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Konstantin Knauf reopened FLINK-13638: -------------------------------------- Re-opening in accordance with https://issues.apache.org/jira/browse/FLINK-23206. > Refactor RemoteChannelStateChecker#isProducerConsumerReadyOrAbortConsumption > to return result action > ---------------------------------------------------------------------------------------------------- > > Key: FLINK-13638 > URL: https://issues.apache.org/jira/browse/FLINK-13638 > Project: Flink > Issue Type: Improvement > Components: Runtime / Network > Affects Versions: 1.9.0, 1.10.0 > Reporter: Andrey Zagrebin > Priority: Minor > Labels: auto-closed > > RemoteChannelStateChecker#isProducerConsumerReadyOrAbortConsumption either > triggers some action (fail or cancel) or returns a decision (trigger new > partition check or not). It would be more symmetric if this class would not > trigger any action but only return a decision what to do: > > {code:java} > enum Action { > FAIL(Throwable cause), > CANCEL(String msg), > TRIGGER_PARTITION_CHECK, NOOP > } > {code} > > Then the caller would be responsible for making the action. That way this > class would only need access to > responseHandle{{.getProducerExecutionState()}} and not responseHandle{{ > }}itself. > From PR discussion > [https://github.com/apache/flink/pull/8463#discussion_r288290783] -- This message was sent by Atlassian Jira (v8.3.4#803005)