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

feat(k8s): do not set mesh owner reference on synced resources #9882

Conversation

jakubdyszkiewicz
Copy link
Contributor

Checklist prior to review

I investigated KDS NACKs in E2E tests and all of them are caused by mesh owner reference.
What is interesting is that we don't set Mesh owner reference on Universal (because we go directly thorough store, not resource manager), that's why the only NACKs we saw were from Kube zones.

Setting mesh owner reference caused the following problems:

  • Policy is synced before mesh - fails because mesh is not present so we cannot set an owner
  • Resource not found on delete - fails because resource was first deleted by owner mechanism

Additionally, I disabled secret delete validation on synced resources. This also caused a race when you delete Secret before Mesh. It was also only applied on Kube because of same reasons (store vs manager).

After this change, I see 0 NACKs on KDS in the multizone suite.

Also, first I tried ordering resources over KDS, but not waiting for ACK resulted races as well. I think it's just more correct to trust the source of truth (other CP that manages resource).

  • Link to relevant issue as well as docs and UI issues --
  • This will not break child repos: it doesn't hardcode values (.e.g "kumahq" as a image registry) and it will work on Windows, system specific functions like syscall.Mkfifo have equivalent implementation on the other OS --
  • Tests (Unit test, E2E tests, manual test on universal and k8s) --
    • Don't forget ci/ labels to run additional/fewer tests
  • Do you need to update UPGRADE.md? --
  • Does it need to be backported according to the backporting policy? (this GH action will add "backport" label based on these file globs, if you want to prevent it from adding the "backport" label use no-backport-autolabel label) --

Signed-off-by: Jakub Dyszkiewicz <jakub.dyszkiewicz@gmail.com>
@jakubdyszkiewicz jakubdyszkiewicz requested a review from a team as a code owner April 9, 2024 08:51
@jakubdyszkiewicz jakubdyszkiewicz requested review from Automaat, bartsmykla and lobkovilya and removed request for a team April 9, 2024 08:51
Copy link
Contributor

@lobkovilya lobkovilya left a comment

Choose a reason for hiding this comment

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

Nice! I like the idea 👍

@jakubdyszkiewicz jakubdyszkiewicz merged commit 39495fb into kumahq:master Apr 9, 2024
15 checks passed
@lahabana lahabana changed the title feat(kuma-cp): do not set mesh owner reference on synced resources feat(k8s): do not set mesh owner reference on synced resources Apr 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants