args

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2018 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package args contains the argument list, defined as a struct, along with a method that validates passed-in args

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ArgumentList

type ArgumentList struct {
	sdkArgs.DefaultArgumentList
	Username               string `default:"" help:"The username for the PostgreSQL database"`
	Password               string `default:"" help:"The password for the specified username"`
	Hostname               string `default:"localhost" help:"The PostgreSQL hostname to connect to"`
	Port                   string `default:"5432" help:"The port to connect to the PostgreSQL database"`
	CollectionList         string `` /* 132-byte string literal not displayed */
	EnableSSL              bool   `default:"false" help:"If true will use SSL encryption, false will not use encryption"`
	TrustServerCertificate bool   `` /* 141-byte string literal not displayed */
	Pgbouncer              bool   `default:"false" help:"Collects metrics from PgBouncer instance. Assumes connection is through PgBouncer."`
	SSLRootCertLocation    string `default:"" help:"Absolute path to PEM encoded root certificate file"`
	SSLCertLocation        string `default:"" help:"Absolute path to PEM encoded client cert file"`
	SSLKeyLocation         string `default:"" help:"Absolute path to PEM encoded client key file"`
	Timeout                string `default:"10" help:"Maximum wait for connection, in seconds. Set 0 for no timeout"`
}

ArgumentList struct that holds all PostgreSQL arguments

func (ArgumentList) GetCollectionList added in v0.1.0

func (al ArgumentList) GetCollectionList() DatabaseList

GetCollectionList unmarshals the argument collection list into a DatabaseList

func (ArgumentList) Validate

func (al ArgumentList) Validate() error

Validate validates PostgreSQl arguments

type DatabaseList added in v0.1.0

type DatabaseList map[string]SchemaList

DatabaseList is a map from database name to SchemaLists to collect

type SchemaList added in v0.1.0

type SchemaList map[string]TableList

SchemaList is a map from schema name to TableList to collect

type TableList added in v0.1.0

type TableList map[string][]string

TableList is a map from table name to an array of indexes to collect

Jump to

Keyboard shortcuts

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