election

package
v0.0.0-...-e20221d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 17, 2023 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LeaderElection

type LeaderElection interface {
	Campaign(ctx context.Context) error
	Resign(ctx context.Context) error
	IsLeader(ctx context.Context) (bool, error)
}

func NewEtcdLeaderElection

func NewEtcdLeaderElection(client *clientV3.Client, key, id string, ttl int) LeaderElection

NewEtcdLeaderElection creates a new instance of etcdLeaderElection.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL