postgresql

package
v5.0.0-alpha4.0...-4074df0 Latest Latest
Warning

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

Go to latest
Published: Nov 15, 2016 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Overview

Package postgresql is a Metricbeat module that contains MetricSets.

Package postgresql is Metricbeat module for PostgreSQL server.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetEnvDSN

func GetEnvDSN() string

func GetEnvPassword

func GetEnvPassword() string

func GetEnvUsername

func GetEnvUsername() string

func ParseURL

func ParseURL(url, username, password string, timeout time.Duration) (string, error)

ParseURL parses the given URL and overrides the values of username, password and timeout if given. Returns a connection string in the form of `user=pass` ready to be passed to the sql.Open call. Code adapted from the pg driver: https://github.com/lib/pq/blob/master/url.go#L32

func QueryStats

func QueryStats(db *sql.DB, query string) ([]map[string]interface{}, error)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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