You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2022/06/30 15:00:04 UTC

[GitHub] [flink-kubernetes-operator] morhidi commented on a diff in pull request #283: [FLINK-28228] Never skip generations when observing already upgraded deployment

morhidi commented on code in PR #283:
URL: https://github.com/apache/flink-kubernetes-operator/pull/283#discussion_r911135037


##########
flink-kubernetes-operator/src/main/java/org/apache/flink/kubernetes/operator/observer/deployment/AbstractDeploymentObserver.java:
##########
@@ -262,8 +262,11 @@ private void onMissingDeployment(FlinkDeployment deployment) {
      * @param context Context for reconciliation.
      */
     private void checkIfAlreadyUpgraded(FlinkDeployment flinkDep, Context context) {
-        Optional<Deployment> depOpt = context.getSecondaryResource(Deployment.class);
         var status = flinkDep.getStatus();
+        if (status.getReconciliationStatus().getLastReconciledSpec() == null) {

Review Comment:
   Would could probably introduce an isFirstDeployment() getter to the DepoymentStatus. I found this check in the code in multiple places.



-- 
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: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org