pd

package
v2.0.0 Latest Latest
Warning

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

Go to latest
Published: Dec 5, 2025 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	InitialClusterStateNew      = "new"
	InitialClusterStateExisting = "existing"
)

Variables

This section is empty.

Functions

func GetAdvertiseClientURLs

func GetAdvertiseClientURLs(pd *v1alpha1.PD, scheme string) string

Types

type Config

type Config struct {
	Name    string `toml:"name"`
	DataDir string `toml:"data-dir"`

	ClientUrls          string `toml:"client-urls"`
	PeerUrls            string `toml:"peer-urls"`
	AdvertiseClientUrls string `toml:"advertise-client-urls"`
	AdvertisePeerUrls   string `toml:"advertise-peer-urls"`

	InitialCluster      string `toml:"initial-cluster"`
	InitialClusterState string `toml:"initial-cluster-state"`
	InitialClusterToken string `toml:"initial-cluster-token"`
	Join                string `toml:"join"`

	Security Security `toml:"security"`
}

Config is a subset config of pd Only our managed fields are defined in here

func (*Config) Overlay

func (c *Config) Overlay(cluster *v1alpha1.Cluster, pd *v1alpha1.PD, peers []*v1alpha1.PD) error

func (*Config) Validate

func (c *Config) Validate() error

type Security

type Security struct {
	// CAPath is the path of file that contains list of trusted SSL CAs.
	CAPath string `toml:"cacert-path"`
	// CertPath is the path of file that contains X509 certificate in PEM format.
	CertPath string `toml:"cert-path"`
	// KeyPath is the path of file that contains X509 key in PEM format.
	KeyPath string `toml:"key-path"`
}

Jump to

Keyboard shortcuts

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