database

package
v0.0.0-...-e765db0 Latest Latest
Warning

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

Go to latest
Published: May 22, 2021 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ProviderSet = wire.NewSet(NewOptions, NewRedis)

ProviderSet is a provider set for wire

Functions

func NewRedis

func NewRedis(o *Options) (*redis.Pool, error)

NewRedis serve caller to create a redis client

Types

type Options

type Options struct {
	URL string `json:"url" yaml:"url"`
}

Options declare database configuration

func NewOptions

func NewOptions(v *viper.Viper, logger *zap.Logger) (*Options, error)

NewOptions serve caller to create an Options

Jump to

Keyboard shortcuts

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