Documentation ¶
Index ¶
- type EtcdLock
- func (e *EtcdLock) Close() error
- func (e *EtcdLock) Features() []lock.Feature
- func (e *EtcdLock) Init(metadata lock.Metadata) error
- func (e *EtcdLock) LockKeepAlive(ctx context.Context, request *lock.LockKeepAliveRequest) (*lock.LockKeepAliveResponse, error)
- func (e *EtcdLock) OnLogLevelChanged(outputLevel logger.LogLevel)
- func (e *EtcdLock) TryLock(ctx context.Context, req *lock.TryLockRequest) (*lock.TryLockResponse, error)
- func (e *EtcdLock) Unlock(ctx context.Context, req *lock.UnlockRequest) (*lock.UnlockResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EtcdLock ¶
type EtcdLock struct {
// contains filtered or unexported fields
}
Etcd lock store
func (*EtcdLock) LockKeepAlive ¶
func (e *EtcdLock) LockKeepAlive(ctx context.Context, request *lock.LockKeepAliveRequest) (*lock.LockKeepAliveResponse, error)
LockKeepAlive try to renewal lease
func (*EtcdLock) OnLogLevelChanged ¶
func (*EtcdLock) TryLock ¶
func (e *EtcdLock) TryLock(ctx context.Context, req *lock.TryLockRequest) (*lock.TryLockResponse, error)
Node tries to acquire a etcd lock
func (*EtcdLock) Unlock ¶
func (e *EtcdLock) Unlock(ctx context.Context, req *lock.UnlockRequest) (*lock.UnlockResponse, error)
Node tries to release a etcd lock
Click to show internal directories.
Click to hide internal directories.