-
Notifications
You must be signed in to change notification settings - Fork 136
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
[YUNIKORN-2850] Watch configmap only in yunikorn's deployed namespace #942
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: 400Ping <[email protected]>
Signed-off-by: 400Ping <[email protected]>
Here is my make test results: |
I see, I accidentally changed the imports. I will change it back now. |
Signed-off-by: 400Ping <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand this PR in its current form. Besides the test cases, there are two main changes:
informers.go
: it's just reformattingmain.go
: bail out if namespace = "". But even the original code passes the namespace toadmission.NewInformers()
.
So what's the fundamental change here? What am I missing?
I also disagree with the main.go
modification because that would result in an inconsistent behavior: the admission controller would crash loop if namespace == "" but the scheduler wouldn't.
This reverts commit 380a257.
This reverts commit facfa3a. :igit push origin YUNIKORN-2850
This reverts commit 8e936b0.
Signed-off-by: 400Ping <[email protected]>
Signed-off-by: 400Ping <[email protected]>
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #942 +/- ##
==========================================
- Coverage 68.05% 68.02% -0.04%
==========================================
Files 70 70
Lines 9194 9194
==========================================
- Hits 6257 6254 -3
- Misses 2730 2732 +2
- Partials 207 208 +1 ☔ View full report in Codecov by Sentry. |
This reverts commit 644e2bd.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
-1. You cannot scope the entire informer factory to a single namespace. This is used by all predicate logic, and must be able to read Kubernetes objects from multiple namespaces.
I see, I am working on it. |
What is this PR for?
Currently, Yunikorn uses configmap informer to handle configuration hot reload.
However, In current implementation informer watches all namespaces even only need to watch namespace in which yunikorn is deployed. It causes in efficient behavior when sync and cache configmap states. If there is too many unrelated configmap in other namespace cause long recovery time to list and memory presure to handle configmap caches which is redundant.
So, If we could replace configmap informer to namespace restricted one, it would improve startup / recovery time and reduce memory usage.
What type of PR is it?
What is the Jira issue?
https://issues.apache.org/jira/browse/YUNIKORN-2850