redis

package
v0.5.12 Latest Latest
Warning

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

Go to latest
Published: Apr 7, 2021 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	Get(key string) (string, error)
	Set(key string, value interface{}, ttl time.Duration) error
}

Client Redis client abstraction

type ClientImpl

type ClientImpl struct{}

ClientImpl Real Redis client

func (ClientImpl) Get

func (r ClientImpl) Get(key string) (string, error)

Get Get value from Redis

func (ClientImpl) Set

func (r ClientImpl) Set(key string, value interface{}, ttl time.Duration) error

Set Set value to Redis. TLL value 0 means forever.

type Connection

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

Connection Contains lazy Redis connection

Jump to

Keyboard shortcuts

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