postgres

package
v0.0.0-...-c3423aa Latest Latest
Warning

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

Go to latest
Published: Dec 22, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package postgres is the native client probe for PostgreSQL

Index

Constants

View Source
const Kind string = "PostgreSQL"

Kind is the type of driver

Variables

This section is empty.

Functions

This section is empty.

Types

type PostgreSQL

type PostgreSQL struct {
	conf.Options  `yaml:",inline"`
	ClientOptions []pgdriver.Option `yaml:"-" json:"-"`
}

revive:disable PostgreSQL is the PostgreSQL client

func New

func New(opt conf.Options) (*PostgreSQL, error)

New create a PostgreSQL client

func (*PostgreSQL) Kind

func (r *PostgreSQL) Kind() string

Kind return the name of client

func (*PostgreSQL) Probe

func (r *PostgreSQL) Probe() (bool, string)

Probe do the health check

func (*PostgreSQL) ProbeWithDataChecking

func (r *PostgreSQL) ProbeWithDataChecking() (bool, string)

ProbeWithDataChecking do the health check with data checking

func (*PostgreSQL) ProbeWithPing

func (r *PostgreSQL) ProbeWithPing() (bool, string)

ProbeWithPing do the health check with ping & Select 1;

Jump to

Keyboard shortcuts

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