redis

package
v0.0.0-...-3301c0c Latest Latest
Warning

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

Go to latest
Published: Aug 22, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewAdapter

func NewAdapter(opt *RingOptions, opts ...AdapterOptions) cache.Adapter

NewAdapter initializes Redis adapter.

Types

type Adapter

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

func (*Adapter) Get

func (a *Adapter) Get(key uint64) ([]byte, bool)

Get implements the cache Adapter interface Get method.

func (*Adapter) Release

func (a *Adapter) Release(key uint64) error

Release implements the cache Adapter interface Release method.

func (*Adapter) Set

func (a *Adapter) Set(key uint64, response []byte, expiration time.Time) error

Set implements the cache Adapter interface Set method.

type AdapterOptions

type AdapterOptions func(a *Adapter)

func WithDebug

func WithDebug(debug bool) AdapterOptions

type RingOptions

type RingOptions redis.RingOptions

Jump to

Keyboard shortcuts

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