nrredigo

package module
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 18, 2019 License: MIT Imports: 5 Imported by: 0

README

nrredigo

CI GoDoc

Redigo connection wrapper with New Relic instrumentation for Go.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config added in v0.1.0

type Config struct {
	DBName       string
	Host         string
	PortPathOrID string
}

Config contains metadata to send to New Relic.

type Option added in v0.1.0

type Option func(*Config)

Option configures a Config object.

func WithDBName added in v0.1.0

func WithDBName(dbName string) Option

WithDBName sets a DB name.

func WithHost added in v0.1.0

func WithHost(host string) Option

WithHost sets a DB host.

func WithPortPathOrID added in v0.1.0

func WithPortPathOrID(v string) Option

WithPortPathOrID sets a DB port, path or id.

type Pool

type Pool interface {
	GetContext(ctx context.Context) (redis.Conn, error)
}

Pool is an interface for representing a pool of Redis connections

func Wrap added in v0.1.0

func Wrap(p Pool, opts ...Option) Pool

Jump to

Keyboard shortcuts

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