database

package
v0.0.0-...-c50d277 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2019 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Open

func Open(ctx context.Context, cfg Config) (driver.Database, error)

Open knows how to open a database connection based on the configuration.

func StatusCheck

func StatusCheck(ctx context.Context, db driver.Database) error

StatusCheck returns nil if it can successfully talk to the database. It returns a non-nil error otherwise.

Types

type Config

type Config struct {
	User     string
	Password string
	Host     []string
	Name     string
}

Config is the required properties to use the database.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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