lburgazzoli commented on code in PR #3480:
URL: https://github.com/apache/camel-k/pull/3480#discussion_r929782933


##########
pkg/controller/integration/kits.go:
##########
@@ -82,6 +82,18 @@ func lookupKitsForIntegration(ctx context.Context, c 
ctrl.Reader, integration *v
        return kits, nil
 }
 
+// sameOrMatch returns whether the v1.IntegrationKit ios the one used by the 
v1.Integration or if it meets the
+// requirements of the v1.Integration.
+func sameOrMatch(kit *v1.IntegrationKit, integration *v1.Integration) (bool, 
error) {
+       if integration.Status.IntegrationKit != nil {
+               if integration.Status.IntegrationKit.Namespace == kit.Namespace 
&& integration.Status.IntegrationKit.Name == kit.Name {
+                       return true, nil
+               }
+       }
+
+       return integrationMatches(integration, kit)

Review Comment:
   For what I understood, in the case the status of a kit should not influence 
the trigger as in fact every change to a kit should result in a reconcile being 
triggered. Then the integration controller should decide what to do so I guess 
your changes are improving also this case.



-- 
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: commits-unsubscr...@camel.apache.org

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

Reply via email to