You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Stefan Richter (JIRA)" <ji...@apache.org> on 2017/10/13 08:01:00 UTC
[jira] [Commented] (FLINK-6684) Remove AsyncCheckpointRunnable from
StreamTask
[ https://issues.apache.org/jira/browse/FLINK-6684?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16203174#comment-16203174 ]
Stefan Richter commented on FLINK-6684:
---------------------------------------
Not sure if this issue is actually valid, because most checkpoints are from the event processing thread when reading a barrier and not from {{Task::triggerCheckpointBarrier}}. That was a mistake here.
> Remove AsyncCheckpointRunnable from StreamTask
> ----------------------------------------------
>
> Key: FLINK-6684
> URL: https://issues.apache.org/jira/browse/FLINK-6684
> Project: Flink
> Issue Type: Improvement
> Components: State Backends, Checkpointing
> Reporter: Stefan Richter
> Assignee: Bowen Li
>
> Right now, {{StreamTask}} executes {{AsyncCheckpointRunnable}} to run the async part of a snapshot. However, it seems that currently the main reason for executing this code in a separate tread is to avoid its execution under the checkpoint lock, so that processing can proceed.
> Actually, the checkpoint is already triggered asynchronously, in {{Task::triggerCheckpointBarrier}}. We could also execute the checkpointing without executing {{AsyncCheckpointRunnable}}, by just running the code inside the thread that is spawned in {{Task::triggerCheckpointBarrier}}. We could simply
> 1) Run the synchronous part of the checkpoint under the checkpointing lock.
> 2) Run the asynchronous part of the checkpoint without holding the checkpointing lock.
> 3) Returning a {{Future}} from {{StatefulTask::triggerCheckpoint}} when called from {{Task::triggerCheckpointBarrier}}.
> This would simplify the code and make the usage of the {{SafetyNetCloseableRegistry}} possible as intended.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)