argoproj-labs / argo-rollouts-manager

Kubernetes Operator for Argo Rollouts controller.
https://argo-rollouts-manager.readthedocs.io/en/latest/
Apache License 2.0
93 stars 304 forks source link

reflect.DeepEqual does not work well when comparing expected Rollouts Deployment resource and live Rollouts Deployment resource #47

Closed jgwest closed 6 months ago

jgwest commented 6 months ago

We have logic in deployment.go which attempts to compare the expected (target) contents of the Argo Rollouts Deployment resource with the live on-cluster contents of that resource, and iff they differ it will update the live copy.

However, at present, that logic will always cause an Update, because reflect.DeepEqual() is matching fields with default values that are set in the live object, but not set in the expected object.

jgwest commented 6 months ago

Red Hat External Tracker: https://issues.redhat.com/browse/GITOPS-4207