Documentation ¶
Index ¶
- type RedisLocker
- func (r *RedisLocker) Close()
- func (r *RedisLocker) Delete(lockKey *distlock.LockKey)
- func (r *RedisLocker) Exists(lockKey *distlock.LockKey) bool
- func (r *RedisLocker) Get(lockKey *distlock.LockKey) string
- func (r *RedisLocker) Keep(lockKey *distlock.LockKey, val string, expire time.Duration)
- func (r *RedisLocker) Set(lockKey *distlock.LockKey, val string, expire time.Duration)
- func (r *RedisLocker) SetIfAbsent(lockKey *distlock.LockKey, val string, expire time.Duration) bool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RedisLocker ¶
type RedisLocker struct {
// contains filtered or unexported fields
}
func New ¶
func New(addrs []string) *RedisLocker
func (*RedisLocker) Close ¶
func (r *RedisLocker) Close()
func (*RedisLocker) Delete ¶
func (r *RedisLocker) Delete(lockKey *distlock.LockKey)
func (*RedisLocker) SetIfAbsent ¶
Click to show internal directories.
Click to hide internal directories.