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

[release-4.9] Bug 2002621: serviceChanged: Fix internalTrafficPolicy #295

Conversation

openshift-cherrypick-robot
Copy link

@openshift-cherrypick-robot openshift-cherrypick-robot commented Sep 9, 2021

This is an automated cherry-pick of #294

/assign Miciah


Kubernetes 1.22 (OpenShift 4.9) enabled a new spec.internalTrafficPolicy field in Service objects. When a Service is created without specifying a value for this new field, the API sets a default value. Before this PR, the operator would try to revert the value that the API set for this new field. This PR changes the operator's logic so that when the operator checks the Service to determine whether an update is required, the operator treats the empty value and default value for spec.internalTrafficPolicy as equal so that it doesn't detect the API's defaulting as a change from the expected Service definition. This PR thus prevents the operator's update logic from making unnecessary API calls to try repeatedly to revert the default value that the API sets.

When comparing services to determine whether an update is required, treat
the empty value and default value for spec.internalTrafficPolicy as equal.

Before this commit, the update logic would keep trying to revert the
default value that the API set for the service's internal traffic policy.

The spec.internalTrafficPolicy field is newly enabled in Kubernetes
1.22 (OpenShift 4.9).

This commit fixes bug 2002461.

https://bugzilla.redhat.com/show_bug.cgi?id=2002461

* pkg/operator/controller/controller_dns_service.go (serviceChanged): Use
the new cmpServiceInternalTrafficPolicyType function so that two services
are considered equal if the only difference between them is that one does
not specify internal traffic policy and the other service has the default
value.
(cmpServiceInternalTrafficPolicyType): New function.
* pkg/operator/controller/controller_dns_service_test.go
(TestDNSServiceChanged): Verify that serviceChanged returns false if the
only mutation is that the internal traffic policy has been updated from
empty to the default value.
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Sep 9, 2021

@openshift-cherrypick-robot: Bugzilla bug 2002461 has been cloned as Bugzilla bug 2002621. Retitling PR to link against new bug.
/retitle [release-4.9] Bug 2002621: serviceChanged: Fix internalTrafficPolicy

In response to this:

[release-4.9] Bug 2002461: serviceChanged: Fix internalTrafficPolicy

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-ci openshift-ci bot changed the title [release-4.9] Bug 2002461: serviceChanged: Fix internalTrafficPolicy [release-4.9] Bug 2002621: serviceChanged: Fix internalTrafficPolicy Sep 9, 2021
@openshift-ci openshift-ci bot added bugzilla/severity-medium Referenced Bugzilla bug's severity is medium for the branch this PR is targeting. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. labels Sep 9, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Sep 9, 2021

@openshift-cherrypick-robot: This pull request references Bugzilla bug 2002621, which is valid. The bug has been moved to the POST state. The bug has been updated to refer to the pull request using the external bug tracker.

6 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target release (4.9.0) matches configured target release for branch (4.9.0)
  • bug is in the state NEW, which is one of the valid states (NEW, ASSIGNED, ON_DEV, POST, POST)
  • dependent bug Bugzilla bug 2002461 is in the state MODIFIED, which is one of the valid states (MODIFIED, ON_QA, VERIFIED)
  • dependent Bugzilla bug 2002461 targets the "4.10.0" release, which is one of the valid target releases: 4.10.0
  • bug has dependents

Requesting review from QA contact:
/cc @lihongan

In response to this:

[release-4.9] Bug 2002621: serviceChanged: Fix internalTrafficPolicy

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@candita
Copy link
Contributor

candita commented Sep 10, 2021

/retest

@ShudiLi
Copy link
Member

ShudiLi commented Sep 15, 2021

/bugzilla cc-qa

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Sep 15, 2021

@ShudiLi: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla cc-qa

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-ci openshift-ci bot added bugzilla/invalid-bug Indicates that a referenced Bugzilla bug is invalid for the branch this PR is targeting. and removed bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. labels Sep 15, 2021
@ShudiLi
Copy link
Member

ShudiLi commented Sep 15, 2021

Verified by cluster-bot according to the pre-merge process, please also refer to the below link.
https://bugzilla.redhat.com/show_bug.cgi?id=2002621#c1

@ShudiLi
Copy link
Member

ShudiLi commented Sep 15, 2021

/lgtm
/label qe-approved

@openshift-ci openshift-ci bot added the qe-approved Signifies that QE has signed off on this PR label Sep 15, 2021
@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Sep 15, 2021
@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Sep 16, 2021

@openshift-bot: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Sep 17, 2021

@openshift-bot: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Sep 18, 2021

@openshift-bot: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Sep 19, 2021

@openshift-bot: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 7, 2021

@openshift-bot: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 8, 2021

@openshift-bot: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 9, 2021

@openshift-bot: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 10, 2021

@openshift-bot: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 11, 2021

@openshift-bot: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 12, 2021

@openshift-bot: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 13, 2021

@openshift-bot: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 14, 2021

@openshift-bot: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 15, 2021

@openshift-bot: This pull request references Bugzilla bug 2002621, which is invalid:

  • expected the bug to target the "4.9.0" release, but it targets "4.9.z" instead

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/bugzilla refresh

Recalculating validity in case the underlying Bugzilla bug has changed.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@sdodson
Copy link
Member

sdodson commented Oct 15, 2021

/bugzilla refresh

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 15, 2021

@sdodson: An error was encountered querying GitHub for users with public email (shudili@redhat.com) for bug 2002621 on the Bugzilla server at https://bugzilla.redhat.com. No known errors were detected, please see the full error message for details.

Full error message. non-200 OK status code: 403 Forbidden body: "{\n \"documentation_url\": \"https://docs.github.com/en/free-pro-team@latest/rest/overview/resources-in-the-rest-api#secondary-rate-limits\",\n \"message\": \"You have exceeded a secondary rate limit. Please wait a few minutes before you try again.\"\n}\n"

Please contact an administrator to resolve this issue, then request a bug refresh with /bugzilla refresh.

In response to this:

/bugzilla refresh

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@sdodson
Copy link
Member

sdodson commented Oct 15, 2021

/bugzilla refresh

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 15, 2021

@sdodson: This pull request references Bugzilla bug 2002621, which is valid.

6 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target release (4.9.z) matches configured target release for branch (4.9.z)
  • bug is in the state POST, which is one of the valid states (NEW, ASSIGNED, ON_DEV, POST, POST)
  • dependent bug Bugzilla bug 2002461 is in the state VERIFIED, which is one of the valid states (VERIFIED, RELEASE_PENDING, CLOSED (ERRATA), CLOSED (CURRENTRELEASE))
  • dependent Bugzilla bug 2002461 targets the "4.10.0" release, which is one of the valid target releases: 4.10.0
  • bug has dependents

No GitHub users were found matching the public email listed for the QA contact in Bugzilla (shudili@redhat.com), skipping review request.

In response to this:

/bugzilla refresh

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-ci openshift-ci bot added bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. and removed bugzilla/invalid-bug Indicates that a referenced Bugzilla bug is invalid for the branch this PR is targeting. labels Oct 15, 2021
@Miciah Miciah added the backport-risk-assessed Indicates a PR to a release branch has been evaluated and considered safe to accept. label Oct 18, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 18, 2021

@openshift-cherrypick-robot: An error was encountered querying GitHub for users with public email (shudili@redhat.com) for bug 2002621 on the Bugzilla server at https://bugzilla.redhat.com. No known errors were detected, please see the full error message for details.

Full error message. non-200 OK status code: 403 Forbidden body: "{\n \"documentation_url\": \"https://docs.github.com/en/free-pro-team@latest/rest/overview/resources-in-the-rest-api#secondary-rate-limits\",\n \"message\": \"You have exceeded a secondary rate limit. Please wait a few minutes before you try again.\"\n}\n"

Please contact an administrator to resolve this issue, then request a bug refresh with /bugzilla refresh.

In response to this:

[release-4.9] Bug 2002621: serviceChanged: Fix internalTrafficPolicy

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@mrunalp mrunalp added the cherry-pick-approved Indicates a cherry-pick PR into a release branch has been approved by the release branch manager. label Oct 21, 2021
@openshift-merge-robot openshift-merge-robot merged commit eedd0dc into openshift:release-4.9 Oct 21, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 21, 2021

@openshift-cherrypick-robot: All pull requests linked via external trackers have merged:

Bugzilla bug 2002621 has been moved to the MODIFIED state.

In response to this:

[release-4.9] Bug 2002621: serviceChanged: Fix internalTrafficPolicy

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-bot
Copy link
Contributor

[ART PR BUILD NOTIFIER]

This PR has been included in build ose-cluster-dns-operator-container-v4.9.0-202311250023.p0.geedd0dc.assembly.stream for distgit ose-cluster-dns-operator.
All builds following this will include this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. backport-risk-assessed Indicates a PR to a release branch has been evaluated and considered safe to accept. bugzilla/severity-medium Referenced Bugzilla bug's severity is medium for the branch this PR is targeting. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. cherry-pick-approved Indicates a cherry-pick PR into a release branch has been approved by the release branch manager. lgtm Indicates that a PR is ready to be merged. qe-approved Signifies that QE has signed off on this PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

8 participants