redis

package
v0.0.0-...-9310dd6 Latest Latest
Warning

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

Go to latest
Published: Feb 10, 2018 License: MIT Imports: 5 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 `json:"host" env:"REDIS_HOST"`
	Port        string `json:"port" env:"REDIS_PORT"`
	Password    string `json:"password" env:"REDIS_PASSWORD"`
	MaxIdle     int    `json:"maxIdle" env:"REDIS_MAX_IDLE"`
	IdleTimeout int64  `json:"idleTimeout" env:"REDIS_IDLE_TIMEOUT"`
}

type Redis

type Redis struct {
	ReceiveQueue chan []byte
	// contains filtered or unexported fields
}

func New

func New() *Redis

func (*Redis) Close

func (m *Redis) Close() error

func (*Redis) Connect

func (m *Redis) Connect() error

func (*Redis) DeleteObject

func (m *Redis) DeleteObject(key string) error

func (*Redis) GetConnection

func (m *Redis) GetConnection() interface{}

func (*Redis) GetObject

func (m *Redis) GetObject(obj interface{}, key string) error

func (*Redis) NewConfig

func (m *Redis) NewConfig() interface{}

func (*Redis) PublishObject

func (m *Redis) PublishObject(channel string, value interface{}) error

func (*Redis) Receive

func (m *Redis) Receive(psc redis.PubSubConn)

func (*Redis) SetObject

func (m *Redis) SetObject(key string, value interface{}, expire int) error

func (*Redis) Subscribe

func (m *Redis) Subscribe(channel string) (redis.PubSubConn, error)

func (*Redis) ValidateBefore

func (m *Redis) ValidateBefore() error

Jump to

Keyboard shortcuts

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