ashangit commented on code in PR #622:
URL:
https://github.com/apache/flink-kubernetes-operator/pull/622#discussion_r1241769472
##########
flink-kubernetes-operator/src/main/java/org/apache/flink/kubernetes/operator/controller/FlinkDeploymentController.java:
##########
@@ -140,6 +141,12 @@ public UpdateControl<FlinkDeployment>
reconcile(FlinkDeployment flinkApp, Contex
previousDeployment,
false);
}
+ // Rely on the last stable spec if rolling back
+ if (flinkApp.getStatus().getReconciliationStatus().getState()
+ == ReconciliationState.ROLLING_BACK) {
+ flinkApp.setSpec(
+
flinkApp.getStatus().getReconciliationStatus().deserializeLastStableSpec());
Review Comment:
I've updated the PR to take in account this case.
I also set the state to Upgrading if the there is a spec change as we don't
want to apply specific code path related to roll back mechanism:
https://github.com/apache/flink-kubernetes-operator/pull/622/files#diff-29ea38a50cac5b4432dd0969bc3e2177e29a5507f8c7bb01b80f605a8740de41R146
I had here to somehow exclude a specific spec diff when it is due to
job.state as we can override this job.state in
https://github.com/apache/flink-kubernetes-operator/blob/main/flink-kubernetes-operator/src/main/java/org/apache/flink/kubernetes/operator/reconciler/ReconciliationUtils.java#L358
--
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]