You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Roman Khachatryan (Jira)" <ji...@apache.org> on 2020/08/26 07:40:00 UTC
[jira] [Commented] (FLINK-18991) Optimize reading InputChannel
state
[ https://issues.apache.org/jira/browse/FLINK-18991?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17184991#comment-17184991 ]
Roman Khachatryan commented on FLINK-18991:
-------------------------------------------
Merged back to FLINK-18990.
> Optimize reading InputChannel state
> -----------------------------------
>
> Key: FLINK-18991
> URL: https://issues.apache.org/jira/browse/FLINK-18991
> Project: Flink
> Issue Type: Improvement
> Components: Runtime / Task
> Reporter: Roman Khachatryan
> Assignee: Roman Khachatryan
> Priority: Major
> Fix For: 1.12.0
>
>
> Curently, channel state is read not sequentially.
> Inverting control would make it more efficient.
> Current call chain:
> {code:java}
> StreamTask.readRecoveredChannelState -> strictly after reading output; when state is *consumed*, requests partitions
> SingleInputGate.readRecoveredState -> submits a task to an executor from main task thread; loop through special channels
> RecoveredInputChannel.readRecoveredState -> loop while has data; buffer = bufferManager.requestBufferBlocking();
> where bufferManager = new BufferManager(inputGate.getMemorySegmentProvider(), this, 0);
> ChannelStateReader.readInputData
> {code}
> Proposed call chain:
> {code:java}
> StreamTask.readRecoveredChannelState -> strictly after reading output; when state is *consumed*, requests partitions
> ChannelStateReader.readInputData (another thread, maybe same executor, maybe change injection)
> loop through state handles ordererd by handle, offset
> request buffer from channel
> pass buffer to RecoveredInputChannel.onRecoveredStateBuffer
> {code}
> Depends on FLINK-18989
--
This message was sent by Atlassian Jira
(v8.3.4#803005)