dm

package
v2.2.0-alpha.3 Latest Latest
Warning

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

Go to latest
Published: Jul 8, 2026 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

This section is empty.

Types

type Config

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

	MasterAddr    string `toml:"master-addr"`
	AdvertiseAddr string `toml:"advertise-addr"`

	PeerUrls          string `toml:"peer-urls"`
	AdvertisePeerUrls string `toml:"advertise-peer-urls"`

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

	OpenAPI bool `toml:"openapi"`

	// SSL fields are top-level in DM master config (not nested under [security])
	SSLCA   string `toml:"ssl-ca"`
	SSLCert string `toml:"ssl-cert"`
	SSLKey  string `toml:"ssl-key"`
}

Config is a subset config of dm-master. Only operator-managed fields are defined here.

func (*Config) Overlay

func (c *Config) Overlay(cluster *v1alpha1.Cluster, dm *v1alpha1.DM, peers []*v1alpha1.DM, join string) error

Overlay fills in operator-managed config fields. peers is the list of all dm-master instances in the same group (used for initial-cluster). join is the existing dm-master client address list for scale-out; empty means bootstrap.

func (*Config) Validate

func (c *Config) Validate() error

Jump to

Keyboard shortcuts

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