-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Cherry pick for v2.1.1 / Cut Release #1540
Cherry pick for v2.1.1 / Cut Release #1540
Conversation
The multiListerWatcher is a composite object encapsulating multiple ListerWatchers and implements the ListerWatcher interface. With the current implementation, when an individual lister fails, the entire List operation fails. This causes no metrics to be shown when KSM has no permissions to a single namespace. In addition to this, the multiListerWatcher takes advantage of internal implementation details if the client-go library by modifiying and relying on the ResourceVersion metadata field. This introduces a bug where reconnecting to the API server will break the multiListerWatcher completely. This commit replaces the multiListerWatcher with individual ListerWatchers per each configured namespace, resolving both issues. Signed-off-by: fpetkovski <filip.petkovsky@gmail.com>
Co-authored-by: Damien Grisonnet <damien.grisonnet@epita.fr>
Co-authored-by: Manuel Rüger <manuel@rueg.eu>
Signed-off-by: FillZpp <FillZpp.pub@gmail.com>
Signed-off-by: Manuel Rüger <manuel@rueg.eu>
8860aef
to
2fa7238
Compare
2fa7238
to
7fb06ae
Compare
77a333f
to
1a87d93
Compare
* [CHANGE] Replace multiListWatcher with independent listWatchers per namespace kubernetes#1499 * [CHANGE] go.mod: Update and minimize dependencies kubernetes#1529 * [BUGFIX] Use BuilderInterface instead of internal/store.Builder in metricshandler kubernetes#1537 * [BUGFIX] Add WithAllowLabels to public BuilderInterface kubernetes#1514
1a87d93
to
c3350d1
Compare
/approve |
@@ -1,3 +1,10 @@ | |||
## v2.1.1 / 2021-07-28 | |||
|
|||
* [CHANGE] Replace multiListWatcher with independent listWatchers per namespace #1499 |
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.
These are changes not bug fixes from what I can tell, do we still want to include them in v2.1.1? Also the bug fixes seem not related to the 2.1 release, so maybe we need to instead cut 2.2? What do you think?
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 believe they are internal changes (that fix certain issues), so suitable for a patch release as they don't add any features or are user visible.
I would release v2.2 with kubernetes 1.22 support once it's out
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.
That sounds good to me, thanks! Should we backport some of the fixes to earlier versions for users pre 1.20 or maybe if they request?
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 think for 1.9.x we can do that upon request and if someone volunteers doing the backports (so we are sure that there's a need).
I believe for 2.0 we don't need to create a new release, 2.1 should work for those users as well.
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.
/lgtm
Thank you!
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: fpetkovski, lilic, mrueg The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@@ -1,3 +1,10 @@ | |||
## v2.1.1 / 2021-07-28 | |||
|
|||
* [CHANGE] Replace multiListWatcher with independent listWatchers per namespace #1499 |
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 think this should be a bugfix since it fixes the permission issue from #1413. Also, we could reuse the release note that @fpetkovski added to his PR:
Fixes a bug where KSM did not export any metrics when it had no permissions for resources in at least one namespace
* [BUGFIX] Use BuilderInterface instead of internal/store.Builder in metricshandler #1537 | ||
* [BUGFIX] Add WithAllowLabels to public BuilderInterface #1514 |
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 would consider both of these PRs changes instead of bug fixes since they are actual improvements made to the builder interface to make it easier for users to extend ksm functionalities.
What this PR does / why we need it:
Cut a new release and backport some fixes.