Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrKeyRequired is returned when key is not passed as parameter in tempdb.Config. ErrKeyRequired = errors.New("creating a new tempdb requires a non-empty key") // ErrValueRequired is returned when value is not passed as parameter in tempdb.Config. ErrValueRequired = errors.New("creating a new tempdb requires a non-empty value") )
Functions ¶
This section is empty.
Types ¶
type Options ¶
type Options struct {
Network string
Addr string
Dialer func() (net.Conn, error)
Password string
DB int
MaxRetries int
DialTimeout time.Duration
ReadTimeout time.Duration
WriteTimeout time.Duration
PoolSize int
PoolTimeout time.Duration
IdleTimeout time.Duration
IdleCheckFrequency time.Duration
ReadOnly bool
TLSConfig *tls.Config
}
Options carries the different variables to tune a newly started redis client, it exposes the same configuration available from https://godoc.org/gopkg.in/redis.v5#Options go client.
type Tempdb ¶
Tempdb stores an expiring (or non-expiring) key/value pair in Redis.
func New ¶
New returns a new temp configured with the variables from the options parameter, or returning an non-nil err if an error occurred while creating redis client.
Click to show internal directories.
Click to hide internal directories.