gyfora commented on a change in pull request #131:
URL: 
https://github.com/apache/flink-kubernetes-operator/pull/131#discussion_r838510223



##########
File path: 
flink-kubernetes-operator/src/main/java/org/apache/flink/kubernetes/operator/controller/FlinkDeploymentController.java
##########
@@ -104,9 +105,31 @@ public DeleteControl cleanup(FlinkDeployment flinkApp, 
Context context) {
 
     @Override
     public UpdateControl<FlinkDeployment> reconcile(FlinkDeployment flinkApp, 
Context context) {
-        FlinkDeployment originalCopy = ReconciliationUtils.clone(flinkApp);
         LOG.info("Starting reconciliation");
+        FlinkDeployment originalCopy = ReconciliationUtils.clone(flinkApp);
+        FlinkDeploymentSpec lastReconciledSpec =
+                
flinkApp.getStatus().getReconciliationStatus().getLastReconciledSpec();
+        if (lastReconciledSpec != null) {
+            Configuration lastValidatedConfig =
+                    FlinkUtils.getEffectiveConfig(
+                            flinkApp.getMetadata(),
+                            lastReconciledSpec,
+                            defaultConfig.getFlinkConfig());

Review comment:
       I think it also fits better into the Observer because using the correct 
config is actually part of the observation logic 




-- 
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]


Reply via email to