redis

package
v0.0.0-...-b3f0c1d Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2024 License: MIT Imports: 3 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 {
	Host               string        `mapstructure:"host"`
	Port               string        `mapstructure:"port"`
	Password           string        `mapstructure:"password"`
	DB                 int           `mapstructure:"db"`
	PoolSize           int           `mapstructure:"pool_size"`
	DialTimeout        time.Duration `mapstructure:"dial_timeout"`
	ReadTimeout        time.Duration `mapstructure:"read_timeout"`
	WriteTimeout       time.Duration `mapstructure:"write_timeout"`
	PoolTimeout        time.Duration `mapstructure:"pool_timeout"`
	IdleCheckFrequency time.Duration `mapstructure:"idle_check_frequency"`
}

type DB

type DB interface {
	Client() *redis.Client
}

type Message

type Message <-chan *redis.Message

type PubSub

type PubSub *redis.PubSub

type RedisDB

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

func New

func New(config Config) *RedisDB

func (*RedisDB) Client

func (r *RedisDB) Client() *redis.Client

Jump to

Keyboard shortcuts

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