Documentation ¶
Index ¶
- func NewLock(ns string, name string, leaseOperator lease.Operator, ...) resourcelock.Interface
- type Lock
- func (l *Lock) Create(ctx context.Context, ler resourcelock.LeaderElectionRecord) error
- func (l *Lock) Describe() string
- func (l *Lock) Get(ctx context.Context) (*resourcelock.LeaderElectionRecord, []byte, error)
- func (l *Lock) Identity() string
- func (l *Lock) RecordEvent(s string)
- func (l *Lock) Update(ctx context.Context, ler resourcelock.LeaderElectionRecord) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewLock ¶
func NewLock(ns string, name string, leaseOperator lease.Operator, rlc resourcelock.ResourceLockConfig) resourcelock.Interface
Types ¶
type Lock ¶
type Lock struct { // LeaseMeta should contain a Name and a Namespace of a // LeaseMeta object that the LeaderElector will attempt to lead. LeaseMeta metav1.ObjectMeta // contains filtered or unexported fields }
func (*Lock) Create ¶
func (l *Lock) Create(ctx context.Context, ler resourcelock.LeaderElectionRecord) error
func (*Lock) Get ¶
func (l *Lock) Get(ctx context.Context) (*resourcelock.LeaderElectionRecord, []byte, error)
func (*Lock) RecordEvent ¶
func (*Lock) Update ¶
func (l *Lock) Update(ctx context.Context, ler resourcelock.LeaderElectionRecord) error
Click to show internal directories.
Click to hide internal directories.