-
Notifications
You must be signed in to change notification settings - Fork 593
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
pluggable leader election strategy #3400
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: lionelvillard 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 |
abd45a1
to
b94541a
Compare
/assign |
Going though the code - looks like functionality like that is needed for HA scalable adapters in Knative eventing. I think we should experiment with it and to do this we need that code to be in knative eventing |
/lgtm |
I see a |
I saw that. It's in the k8s go client lib. |
b94541a
to
c2f66bf
Compare
The following is the coverage report on the affected files.
|
I think we need that code and tests passed. /lgtm |
pkgleaderelection "knative.dev/pkg/leaderelection" | ||
"knative.dev/pkg/logging" | ||
"knative.dev/pkg/system" | ||
) |
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 just came across this trying to enable HA by default for our controlplane components, which eliminates the enabledComponents
and the LeaderElect
fields from knative/pkg.
This code has zero eventing dependencies, and forks a ton of the PKG logic into eventing. 😞
Is there a design or a feature track document for this anywhere...?
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.
this code is almost the same as the one found in PKG except it depends on adapter.Adapter instead of reconciler.LeaderAware. (there was issues with directly imported adapter.Adapter from context.go
so the interface is duplicated in this file).
I would like to consolidate the two together, and maybe reconciler.LeaderAware
is the right abstraction but I'm not sure yet. That's on my TODO list for 0.17.
For #3157
Proposed Changes
Release Note
Docs
Since the implementation provided by k8s is buggy and not optimal (pull only) we need a way to replace it.
Depends on #3384