etcdv3lock

package
v0.0.0-...-5c9bec8 Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2022 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Mutex

type Mutex struct {
	// contains filtered or unexported fields
}

Mutex ...

func NewMutex

func NewMutex(client *clientv3.Client, key string, opts ...concurrency.SessionOption) (mutex *Mutex, err error)

func (*Mutex) Lock

func (mutex *Mutex) Lock(timeout time.Duration) (err error)

Lock ...

func (*Mutex) LockWithCtx

func (mutex *Mutex) LockWithCtx(ctx context.Context) error

LockWithCtx ...

func (*Mutex) TryLock

func (mutex *Mutex) TryLock(timeout time.Duration) (err error)

TryLock ...

func (*Mutex) UnLockWithCtx

func (mutex *Mutex) UnLockWithCtx(ctx context.Context) error

LockWithCtx ...

func (*Mutex) Unlock

func (mutex *Mutex) Unlock() (err error)

Unlock ...

Jump to

Keyboard shortcuts

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