kubernetes/staging/src/k8s.io/client-go/tools/leaderelection/leasecandidate.go

const requeueInterval

type CacheSyncWaiter

type LeaseCandidate

// NewCandidate creates new LeaseCandidate controller that creates a
// LeaseCandidate object if it does not exist and watches changes
// to the corresponding object and renews if PingTime is set.
// WARNING: This is an ALPHA feature. Ensure that the CoordinatedLeaderElection
// feature gate is on.
func NewCandidate(clientset kubernetes.Interface,
	candidateNamespace string,
	candidateName string,
	targetLease string,
	binaryVersion, emulationVersion string,
	preferredStrategies []v1.CoordinatedLeaseStrategy,
) (*LeaseCandidate, CacheSyncWaiter, error) {}

func (c *LeaseCandidate) Run(ctx context.Context) {}

func (c *LeaseCandidate) runWorker(ctx context.Context) {}

func (c *LeaseCandidate) processNextWorkItem(ctx context.Context) bool {}

func (c *LeaseCandidate) enqueueLease() {}

// ensureLease creates the lease if it does not exist and renew it if it exists. Returns the lease and
// a bool (true if this call created the lease), or any error that occurs.
func (c *LeaseCandidate) ensureLease(ctx context.Context) error {}

func (c *LeaseCandidate) newLeaseCandidate() *v1alpha1.LeaseCandidate {}