dl

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 11, 2020 License: MIT Imports: 4 Imported by: 0

README

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EtcdLock

type EtcdLock struct {
}

type Lock

type Lock interface {
	Acquire() error
	Release() error
}

func NewLock

func NewLock() Lock

type RedisLock

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

func NewRedisLock

func NewRedisLock(client *redis.Client, token, resource string, retries, interval int) *RedisLock

func (*RedisLock) Acquire

func (rl *RedisLock) Acquire() error

func (*RedisLock) Release

func (rl *RedisLock) Release() error

type ZookeeperLock

type ZookeeperLock struct {
}

支持其他形式实现的锁

Jump to

Keyboard shortcuts

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