configuration

package
v0.0.0-...-f21c627 Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2018 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// BuildCommit lastest build commit (set by build script)
	BuildCommit = "unknown"
	// BuildTime set by build script
	BuildTime = "unknown"
)

Functions

This section is empty.

Types

type Configuration

type Configuration struct {
	// contains filtered or unexported fields
}

Configuration the application Configuration, based on ENV variables

func New

func New() *Configuration

New initializes a new Configuration from the ENV variables

func (*Configuration) GetLogLevel

func (c *Configuration) GetLogLevel() string

GetLogLevel returns the log level

func (*Configuration) GetPathToConfig

func (c *Configuration) GetPathToConfig() string

GetPathToConfig returns the path to the config file

func (*Configuration) GetPostgresAdminConfig

func (c *Configuration) GetPostgresAdminConfig() string

GetPostgresAdminConfig returns the settings for opening a new connection on a PostgreSQL server

func (*Configuration) GetPostgresAdminPassword

func (c *Configuration) GetPostgresAdminPassword() string

GetPostgresAdminPassword returns the postgres password as set via default, config file, or environment variable

func (*Configuration) GetPostgresConfig

func (c *Configuration) GetPostgresConfig() string

GetPostgresConfig returns the settings for opening a new connection on a PostgreSQL server

func (*Configuration) GetPostgresConnectionMaxIdle

func (c *Configuration) GetPostgresConnectionMaxIdle() int

GetPostgresConnectionMaxIdle returns the number of connections that should be keept alive in the database connection pool at any given time. -1 represents no restrictions/default behavior

func (*Configuration) GetPostgresConnectionMaxOpen

func (c *Configuration) GetPostgresConnectionMaxOpen() int

GetPostgresConnectionMaxOpen returns the max number of open connections that should be open in the database connection pool. -1 represents no restrictions/default behavior

func (*Configuration) GetPostgresConnectionRetrySleep

func (c *Configuration) GetPostgresConnectionRetrySleep() time.Duration

GetPostgresConnectionRetrySleep returns the number of seconds (as set via default, config file, or environment variable) to wait before trying to connect again

func (*Configuration) GetPostgresConnectionTimeout

func (c *Configuration) GetPostgresConnectionTimeout() int64

GetPostgresConnectionTimeout returns the postgres connection timeout as set via default, config file, or environment variable

func (*Configuration) GetPostgresDatabase

func (c *Configuration) GetPostgresDatabase() string

GetPostgresDatabase returns the postgres database as set via default, config file, or environment variable

func (*Configuration) GetPostgresHost

func (c *Configuration) GetPostgresHost() string

GetPostgresHost returns the postgres host as set via default, config file, or environment variable

func (*Configuration) GetPostgresPassword

func (c *Configuration) GetPostgresPassword() string

GetPostgresPassword returns the postgres password as set via default, config file, or environment variable

func (*Configuration) GetPostgresPort

func (c *Configuration) GetPostgresPort() int64

GetPostgresPort returns the postgres port as set via default, config file, or environment variable

func (*Configuration) GetPostgresSSLMode

func (c *Configuration) GetPostgresSSLMode() string

GetPostgresSSLMode returns the postgres sslmode as set via default, config file, or environment variable

func (*Configuration) GetPostgresSuperUser

func (c *Configuration) GetPostgresSuperUser() string

GetPostgresSuperUser returns the postgres superuser as set via default, config file, or environment variable

func (*Configuration) GetPostgresTransactionTimeout

func (c *Configuration) GetPostgresTransactionTimeout() time.Duration

GetPostgresTransactionTimeout returns the number of minutes to timeout a transaction

func (*Configuration) GetPostgresUser

func (c *Configuration) GetPostgresUser() string

GetPostgresUser returns the postgres user as set via default, config file, or environment variable

Jump to

Keyboard shortcuts

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