Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RunWithLeaderElection ¶
RunWithLeaderElection runs the provided runner function with leader election. newRunnerFn might be called multiple times, and it should return another controller instance's Run method each time. RunWithLeaderElection only returns when the context is done, or initial leader election fails.
Types ¶
type Controller ¶
type Controller struct {
// contains filtered or unexported fields
}
Controller is the leader election controller, which observes component identity leases for components that have self-nominated as candidate leaders for leases and elects leaders for those leases, favoring candidates with higher versions.
func NewController ¶
func NewController(leaseInformer coordinationv1informers.LeaseInformer, leaseCandidateInformer coordinationv1alpha1.LeaseCandidateInformer, leaseClient coordinationv1client.CoordinationV1Interface, leaseCandidateClient coordinationv1alpha1client.CoordinationV1alpha1Interface) (*Controller, error)
type LeaseCandidateGCController ¶
type LeaseCandidateGCController struct {
// contains filtered or unexported fields
}
func NewLeaseCandidateGC ¶
func NewLeaseCandidateGC(clientset kubernetes.Interface, gcCheckPeriod time.Duration, leaseCandidateInformer coordinationv1alpha1informers.LeaseCandidateInformer) *LeaseCandidateGCController
NewLeaseCandidateGC creates a new LeaseCandidateGCController.
func (*LeaseCandidateGCController) Run ¶
func (c *LeaseCandidateGCController) Run(ctx context.Context)
Run starts one worker.
Click to show internal directories.
Click to hide internal directories.