Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug 1842741: Fix serviceChanged and daemonsetConfigChanged #174

Commits on Jun 21, 2020

  1. serviceChanged: Fix session affinity, type

    When comparing services to determine whether an update is required, treat
    implicit and explicit default values as equal.
    
    Before this commit, the update logic would keep trying to revert the
    default value that the API set for the service's session affinity or type.
    
    This commit fixes part of bug 1842741.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1842741
    
    * pkg/operator/controller/controller_dns_service.go (serviceChanged): Use
    the new cmpServiceAffinity and cmpServiceType functions so that two
    services are considered equal if the only difference between them is that
    one does not specify the session affinity or type and the other service has
    the default values.
    (cmpServiceAffinity, cmpServiceType): New function.
    * pkg/operator/controller/controller_dns_service_test.go
    (TestDNSServiceChanged): Verify that serviceChanged returns false if the
    only mutation is that the session affinity or type has been updated from
    empty to the default value.
    Miciah committed Jun 21, 2020
    Copy the full SHA
    2472f5a View commit details
    Browse the repository at this point in the history

Commits on Jul 8, 2020

  1. daemonsetConfigChanged: Fix for volume default mode

    When comparing daemonsets to determine whether an update is required, treat
    implicit and explicit default values as equal.
    
    Before this commit, the update logic would keep trying to revert the
    default value that the API set for a volume's default mode.
    
    This commit fixes part of bug 1842741.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1842741
    
    * pkg/operator/controller/controller_dns_daemonset.go
    (daemonsetConfigChanged): Use the new cmpConfigMapVolumeSource and
    cmpSecretVolumeSource functions so that two daemonsets are considered equal
    if the only difference between them is that one does not specify a default
    mode value and the other daemonset specifies the default value.
    (volumeDefaultMode): New constant with the default mode that the API uses
    for configmap and secret volume sources.
    (cmpConfigMapVolumeSource, cmpSecretVolumeSource): New functions.
    * pkg/operator/controller/controller_dns_daemonset_test.go
    (TestDaemonsetConfigChanged): Verify that daemonsetConfigChanged returns
    false if the only mutation is that a volume's default mode value has been
    updated from empty to the default value.
    Miciah committed Jul 8, 2020
    Copy the full SHA
    147d79a View commit details
    Browse the repository at this point in the history