Documentation ¶
Overview ¶
Package pgconfig provides tools for work with Postgres configuration.
Index ¶
- Constants
- type Manager
- func (m *Manager) AdjustRecoveryFiles() error
- func (m *Manager) AppendGeneralConfig(cfg map[string]string) error
- func (m *Manager) ApplyPgControl(pgControl map[string]string) error
- func (m *Manager) ApplyPromotion(cfg map[string]string) error
- func (m *Manager) ApplyRecovery(cfg map[string]string) error
- func (m *Manager) ApplySnapshot(cfg map[string]string) error
- func (m *Manager) ApplySync(cfg map[string]string) error
- func (m *Manager) ApplyUserConfig(cfg map[string]string) error
- func (m *Manager) GetPgVersion() float64
- func (m *Manager) ReadRecoveryConfig() (map[string]string, error)
- func (m *Manager) RemoveRecoveryConfig() error
- func (m *Manager) TruncatePromotionConfig() error
- func (m *Manager) TruncateRecoveryConfig() error
- func (m *Manager) TruncateSyncConfig() error
Constants ¶
const (
// PgConfName defines the name of general Postgres config.
PgConfName = "postgresql.conf"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager defines a struct to correct PostgreSQL configuration.
func NewCorrector ¶
NewCorrector creates a new corrector.
func (*Manager) AdjustRecoveryFiles ¶
AdjustRecoveryFiles adjusts a recovery files.
func (*Manager) AppendGeneralConfig ¶ added in v2.4.0
AppendGeneralConfig appends configuration parameters to a general configuration file.
func (*Manager) ApplyPgControl ¶
ApplyPgControl applies significant configuration parameters extracted by the pg_control tool.
func (*Manager) ApplyPromotion ¶
ApplyPromotion applies promotion configuration parameters.
func (*Manager) ApplyRecovery ¶
ApplyRecovery applies recovery configuration parameters.
func (*Manager) ApplySnapshot ¶
ApplySnapshot applies snapshot configuration parameters.
func (*Manager) ApplyUserConfig ¶
ApplyUserConfig applies user-defined configuration.
func (*Manager) GetPgVersion ¶
GetPgVersion gets a version of Postgres Data.
func (*Manager) ReadRecoveryConfig ¶ added in v2.4.0
ReadRecoveryConfig reads a recovery configuration file.
func (*Manager) RemoveRecoveryConfig ¶ added in v2.4.0
RemoveRecoveryConfig removes a recovery configuration file.
func (*Manager) TruncatePromotionConfig ¶
TruncatePromotionConfig truncates a promotion configuration file.
func (*Manager) TruncateRecoveryConfig ¶ added in v2.4.0
TruncateRecoveryConfig truncates a recovery configuration file.
func (*Manager) TruncateSyncConfig ¶
TruncateSyncConfig truncates a sync configuration file.