redis

package
v0.0.0-...-287be54 Latest Latest
Warning

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

Go to latest
Published: May 12, 2024 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Redis

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

func MakeDB

func MakeDB(host, port, pass string, logger logging.Logger, tracer trace.Tracer) (Redis, error)

func (Redis) Close

func (db Redis) Close() error

func (Redis) Create

func (db Redis) Create(ctx context.Context, article entity.Article) error

func (Redis) Delete

func (db Redis) Delete(ctx context.Context, id string) error

func (Redis) EventHandlers

func (db Redis) EventHandlers() map[event.EventType][]event.Handler

func (Redis) Get

func (db Redis) Get(ctx context.Context, id string) (entity.Article, error)

func (Redis) GetMultiple

func (db Redis) GetMultiple(ctx context.Context, offset, limit string) ([]entity.Article, error)

func (Redis) Ping

func (db Redis) Ping(ctx context.Context) error

func (Redis) Update

func (db Redis) Update(ctx context.Context, article entity.Article) error

Jump to

Keyboard shortcuts

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