sql

package
v2.3.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2017 License: Apache-2.0 Imports: 16 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package sql provides SQL implementations of the storage interface.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Postgres

type Postgres struct {
	Database string
	User     string
	Password string
	Host     string

	SSL PostgresSSL `json:"ssl" yaml:"ssl"`

	ConnectionTimeout int // Seconds
}

Postgres options for creating an SQL db.

func (*Postgres) Open

func (p *Postgres) Open(logger logrus.FieldLogger) (storage.Storage, error)

Open creates a new storage implementation backed by Postgres.

type PostgresSSL

type PostgresSSL struct {
	Mode   string
	CAFile string
	// Files for client auth.
	KeyFile  string
	CertFile string
}

PostgresSSL represents SSL options for Postgres databases.

type SQLite3

type SQLite3 struct {
	// File to
	File string `json:"file"`
}

SQLite3 options for creating an SQL db.

func (*SQLite3) Open

func (s *SQLite3) Open(logger logrus.FieldLogger) (storage.Storage, error)

Open creates a new storage implementation backed by SQLite3

Jump to

Keyboard shortcuts

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