[ 
https://issues.apache.org/jira/browse/FLINK-10202?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16591188#comment-16591188
 ] 

buptljy commented on FLINK-10202:
---------------------------------

[~StephanEwen] Here is my code. I think the checkpoint directory in 
CheckpointCoordinator is still empty even if you set direcotry in 
FsStateBackend.
{code:java}
val env = StreamExecutionEnvironment.getExecutionEnvironment
env.enableCheckpointing(15000)
env.getCheckpointConfig.enableExternalizedCheckpoints(ExternalizedCheckpointCleanup.RETAIN_ON_CANCELLATION)
env.setStateBackend(new FsStateBackend(checkpointDir)){code}
 1. If I don't set state.checkpoint.dir, it will throw exception above.

 2. If i remove the third line, it will be okay.

> Enable configuration for state.checkpoint.dir in StreamExecutionEnvironment
> ---------------------------------------------------------------------------
>
>                 Key: FLINK-10202
>                 URL: https://issues.apache.org/jira/browse/FLINK-10202
>             Project: Flink
>          Issue Type: Improvement
>            Reporter: buptljy
>            Priority: Major
>
> Usually we can set state.checkpoint.dir in flink-conf.yaml, but sometimes we 
> run a flink job locally, and we're not able to set state.checkpoint.dir for 
> background wrapped cluster, which will cause 
> {code:java}
> throw new IllegalStateException("CheckpointConfig says to persist periodic " +
>       "checkpoints, but no checkpoint directory has been configured. You can 
> " +
>       "configure configure one via key '" + 
> ConfigConstants.CHECKPOINTS_DIRECTORY_KEY + "'.");
> {code}
> I wonder if we could provide a public method in *StreamExecutionEnvironment* 
> so that developers can use it to set state.checkpoint.dir for job.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to