Documentation ¶
Index ¶
- func GetRedisPool(name string) *redisPool
- func InitRedisPool(redisConfigs map[string]config.RedisConfig)
- type RedisProxy
- func (rp *RedisProxy) BitCount(ctx context.Context, key string) (int, errors.AppError)
- func (rp *RedisProxy) BitFieldGetU(ctx context.Context, key string, num int, start int) (int64, errors.AppError)
- func (rp *RedisProxy) Decrby(ctx context.Context, key string, v int64) (int64, errors.AppError)
- func (rp *RedisProxy) Del(ctx context.Context, keys ...string) (int, errors.AppError)
- func (rp *RedisProxy) Exist(ctx context.Context, key string) (bool, errors.AppError)
- func (rp *RedisProxy) Expire(ctx context.Context, key string, expire int) (bool, errors.AppError)
- func (rp *RedisProxy) Get(ctx context.Context, key string) (string, errors.AppError)
- func (rp *RedisProxy) GetBit(ctx context.Context, key string, offset int) (int, errors.AppError)
- func (rp *RedisProxy) HDel(ctx context.Context, key string, fields ...interface{}) (int64, errors.AppError)
- func (rp *RedisProxy) HExists(ctx context.Context, key, field string) (bool, errors.AppError)
- func (rp *RedisProxy) HGet(ctx context.Context, key, field string) (string, errors.AppError)
- func (rp *RedisProxy) HMGet(ctx context.Context, key string, fields ...interface{}) (map[string]string, errors.AppError)
- func (rp *RedisProxy) HMSet(ctx context.Context, key string, fieldValue map[string]string) errors.AppError
- func (rp *RedisProxy) HSet(ctx context.Context, key, field, value string) errors.AppError
- func (rp *RedisProxy) Incrby(ctx context.Context, key string, v int64) (int64, errors.AppError)
- func (rp RedisProxy) IsEmpty() bool
- func (rp *RedisProxy) MGet(ctx context.Context, keys ...string) ([]string, errors.AppError)
- func (rp *RedisProxy) MSet(ctx context.Context, fieldValue map[string]string) errors.AppError
- func (rp *RedisProxy) Pool() *redisPool
- func (rp *RedisProxy) ReleaseDistributedLock(ctx context.Context, key string, v string) (bool, errors.AppError)
- func (rp *RedisProxy) Scan(ctx context.Context, index int64, match string, count int) (int64, []string, errors.AppError)
- func (rp *RedisProxy) Set(ctx context.Context, key string, value string) errors.AppError
- func (rp *RedisProxy) SetBit(ctx context.Context, key string, offset int, value int, ex int) errors.AppError
- func (rp *RedisProxy) SetEx(ctx context.Context, key string, value string, ex int) errors.AppError
- func (rp *RedisProxy) TryGetDistributedLock(ctx context.Context, key string, v string, timeOut int) (bool, errors.AppError)
- func (rp *RedisProxy) ZAdd(ctx context.Context, key string, score float64, value string) errors.AppError
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetRedisPool ¶
func GetRedisPool(name string) *redisPool
func InitRedisPool ¶
func InitRedisPool(redisConfigs map[string]config.RedisConfig)
InitRedisPool 初始化redis
Types ¶
type RedisProxy ¶
type RedisProxy struct {
// contains filtered or unexported fields
}
func GetProxyByName ¶
func GetProxyByName(name string) *RedisProxy
GetProxyByName get redis oper proxy
func (*RedisProxy) BitFieldGetU ¶
func (RedisProxy) IsEmpty ¶
func (rp RedisProxy) IsEmpty() bool
func (*RedisProxy) Pool ¶
func (rp *RedisProxy) Pool() *redisPool
func (*RedisProxy) ReleaseDistributedLock ¶
func (*RedisProxy) TryGetDistributedLock ¶
Click to show internal directories.
Click to hide internal directories.