locker

package
v0.1.30 Latest Latest
Warning

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

Go to latest
Published: May 20, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Addr string
}

type LockOptions

type LockOptions struct{}

type Locker

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

func NewLocker

func NewLocker(c Config) *Locker

func (*Locker) Lock

func (l *Locker) Lock(ctx context.Context, key string, ttl time.Duration, opts *LockOptions) (*lock, error)

Try to obtain a lock.

Jump to

Keyboard shortcuts

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