patroni

package
v4.3.2+incompatible Latest Latest
Warning

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

Go to latest
Published: May 27, 2020 License: Apache-2.0 Imports: 9 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (

	// ErrInstanceNotFound is the error thrown when a target instance cannot be found in the cluster
	ErrInstanceNotFound = errors.New("The instance does not exist in the cluster")
)

Functions

This section is empty.

Types

type Client

type Client interface {
	ReloadCluster() error
	RestartCluster() ([]RestartResult, error)
	RestartInstances(instance ...string) ([]RestartResult, error)
}

Client defines the various actions a Patroni client is able to perform against a specified PGCluster

func NewPatroniClient

func NewPatroniClient(restConfig *rest.Config, kubeclientset kubernetes.Interface,
	clusterName, namespace string) Client

NewPatroniClient creates a new Patroni client

type RestartResult

type RestartResult struct {
	Instance string
	Error    error
}

RestartResult represents the result of a cluster restart, specifically the name of the an instance that was restarted within a cluster, and an error that can be populated in the event an instance cannot be successfully restarted.

Jump to

Keyboard shortcuts

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