postgres

package
v1.0.5 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2018 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DBConnect

func DBConnect(pgConnStr string, migrationsPath string) (db.DB, error)

DBConnect initializes connection to postgresql database. github.com/jmoiron/sqlx used to to get work with database. Function tries to ping database and apply migrations using github.com/mattes/migrate. If migrations applying failed database goes to dirty state and requires manual conflict resolution.

Types

This section is empty.

Jump to

Keyboard shortcuts

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