Skip to content

k8s/watchers: fix missing missing CNP/CCNP updates#12143

Merged
tgraf merged 1 commit intomasterfrom
pr/fix-policy-update
Jun 17, 2020
Merged

k8s/watchers: fix missing missing CNP/CCNP updates#12143
tgraf merged 1 commit intomasterfrom
pr/fix-policy-update

Conversation

@aanm
Copy link
Copy Markdown
Member

@aanm aanm commented Jun 17, 2020

Since we were only comparing the spec of a CNP / CCNP, whenever the
cilium-agent received a CNP or CCNP containing a 'specs', any following
updates to that policy wouldn't be enforced in Cilium since the network
policy would be considered equal as the one already being enforced.

As Cilium is already comparing the network policies, before processing
any policy update, we can remove this Spec.Equals.

Fixes: 2d34336 ("use deepequal generated code")
Signed-off-by: André Martins andre@cilium.io

do not ignore Kubernetes event updates for CCNP and CNP with 'specs' field after being created

Since we were only comparing the spec of a CNP / CCNP, whenever the
cilium-agent received a CNP or CCNP containing a 'specs', any following
updates to that policy wouldn't be enforced in Cilium since the network
policy would be considered equal as the one already being enforced.

As Cilium is already comparing the network policies, before processing
any policy update, we can remove this Spec.Equals.

Fixes: 2d34336 ("use deepequal generated code")
Signed-off-by: André Martins <andre@cilium.io>
@aanm aanm added priority/release-blocker kind/regression This functionality worked fine before, but was broken in a newer release of Cilium. labels Jun 17, 2020
@aanm aanm requested a review from a team June 17, 2020 15:01
@maintainer-s-little-helper
Copy link
Copy Markdown

Please set the appropriate release note label.

3 similar comments
@maintainer-s-little-helper
Copy link
Copy Markdown

Please set the appropriate release note label.

@maintainer-s-little-helper
Copy link
Copy Markdown

Please set the appropriate release note label.

@maintainer-s-little-helper
Copy link
Copy Markdown

Please set the appropriate release note label.

@aanm aanm added the release-note/bug This PR fixes an issue in a previous release of Cilium. label Jun 17, 2020
@aanm
Copy link
Copy Markdown
Member Author

aanm commented Jun 17, 2020

test-me-please

Copy link
Copy Markdown
Member

@christarazi christarazi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@coveralls
Copy link
Copy Markdown

Coverage Status

Coverage increased (+0.02%) to 37.087% when pulling a651795 on pr/fix-policy-update into 989eced on master.

@maintainer-s-little-helper maintainer-s-little-helper Bot added the ready-to-merge This PR has passed all tests and received consensus from code owners to merge. label Jun 17, 2020
@tgraf tgraf merged commit 134fdb5 into master Jun 17, 2020
@tgraf tgraf deleted the pr/fix-policy-update branch June 17, 2020 18:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/regression This functionality worked fine before, but was broken in a newer release of Cilium. ready-to-merge This PR has passed all tests and received consensus from code owners to merge. release-note/bug This PR fixes an issue in a previous release of Cilium.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants