locker

package
v0.7.4 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Locker

type Locker interface {
	ObtainLock(
		ctx context.Context,
		key string,
	) (context.Context, context.CancelFunc, error)
}

func NewMemoryLocker

func NewMemoryLocker() Locker

func NewRedisLocker

func NewRedisLocker(
	redisURL string,
	redisPassword string,
) (Locker, error)

Jump to

Keyboard shortcuts

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