bgeng777 commented on a change in pull request #85:
URL:
https://github.com/apache/flink-kubernetes-operator/pull/85#discussion_r830602054
##########
File path:
flink-kubernetes-operator/src/main/java/org/apache/flink/kubernetes/operator/reconciler/JobReconciler.java
##########
@@ -114,6 +119,14 @@ public void reconcile(FlinkDeployment flinkApp, Context
context, Configuration e
}
}
+ private void restart(FlinkDeployment flinkApp, Configuration
effectiveConfig) throws Exception {
+ LOG.info("Restart application cluster now.");
+ String jobIdString = flinkApp.getStatus().getJobStatus().getJobId();
+ JobID jobID = jobIdString != null ? JobID.fromHexString(jobIdString) :
null;
+ flinkService.cancelJob(jobID, UpgradeMode.LAST_STATE, effectiveConfig);
Review comment:
I recheck the JIRA, the restart should be a shortcut of `suspend ->
delete current deployment -> restart job from latest state in a new
deployment", right? If that is the case, I think your code works fine.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]