Documentation ¶
Index ¶
- func New(pool *redis.Pool, keyspace string) cache.Backer
- type Backer
- func (r *Backer) Close()
- func (r *Backer) Delete(key string) error
- func (r *Backer) Exists(key string) (bool, error)
- func (r *Backer) Get(key string) ([]byte, bool, error)
- func (r *Backer) Health() error
- func (r *Backer) Set(key string, value []byte) error
- func (r *Backer) SetExpires(key string, value []byte, ttl time.Duration) error
- func (r *Backer) UpdateExpiration(key string, ttl time.Duration) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Backer ¶
type Backer struct {
// contains filtered or unexported fields
}
func (*Backer) Health ¶
Health returns the current health status of the remote cache.
Possible return values are:
nil - no issues non-nil error - error reported by the remote cache
func (*Backer) SetExpires ¶
SetExpires sets a value in redis using the PSETEX command. The ttl value has millisecond precision.
Click to show internal directories.
Click to hide internal directories.