sql

package
v2.9.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2017 License: Apache-2.0 Imports: 16 Imported by: 0

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