[
https://issues.apache.org/jira/browse/FLINK-27274?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17523597#comment-17523597
]
Zhu Zhu commented on FLINK-27274:
---------------------------------
[~macdoor615] Thanks for sharing the information! I think I know the cause.
I made a mistake that I thought the job will be CANCELED on stop-cluster.sh.
However, it is not.
The fact is that stop-cluster.sh will just shutdown the JobManager process and
the job will transition to SUSPENDED, and then the job will be recovered after
a new cluster is started via start-cluster.sh. This is the expected process.
However, stop-cluster.sh also shuts down the task managers. It may result in
task failures and is possible to result in a job failure. The job will
transitioned to FAILED in this case and can not be recovered later.
To avoid the latter case, you can configure the restart strategy a below:
restart-strategy: fixed-delay
restart-strategy.fixed-delay.delay: 10 s
restart-strategy.fixed-delay.attempts: 2147483647
In this way, the job will not transition to FAILED. It will finally transition
to SUSPENDED and become recoverable.
> Job cannot be recovered, after restarting cluster
> -------------------------------------------------
>
> Key: FLINK-27274
> URL: https://issues.apache.org/jira/browse/FLINK-27274
> Project: Flink
> Issue Type: Bug
> Components: Table SQL / API
> Affects Versions: 1.15.0
> Environment: Flink 1.15.0-rc3
> [https://github.com/apache/flink/archive/refs/tags/release-1.15.0-rc3.tar.gz]
> Reporter: macdoor615
> Priority: Blocker
> Fix For: 1.15.1
>
> Attachments: flink-conf.yaml,
> flink-gum-standalonesession-0-hb3-dev-flink-000.log.3.zip,
> flink-gum-standalonesession-0-hb3-dev-flink-000.log.zip,
> flink-gum-taskexecutor-2-hb3-dev-flink-000.log, log.recover.debug.zip,
> new_cf_alarm_no_recover.yaml.sql
>
>
> 1. execute new_cf_alarm_no_recover.yaml.sql with sql-client.sh
> config file: flink-conf.yaml
> the job run properly
> 2. restart cluster with command
> stop-cluster.sh
> start-cluster.sh
> 3. job cannot be recovered
> log files
> flink-gum-standalonesession-0-hb3-dev-flink-000.log
> flink-gum-taskexecutor-2-hb3-dev-flink-000.log
> 4. not all job can not be recovered, some can, some can not, at same time
> 5. all job can be recovered on Flink 1.14.4
--
This message was sent by Atlassian Jira
(v8.20.1#820001)