mysqlcluster

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Jun 17, 2020 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// MysqlPortName represents the mysql port name.
	MysqlPortName = "mysql"
	// MysqlPort is the default mysql port.
	MysqlPort = constants.MysqlPort

	// OrcTopologyDir path where orc conf secret is mounted
	OrcTopologyDir = constants.OrcTopologyDir

	// SidecarServerPortName name of the port
	SidecarServerPortName = "sidecar-http"
	// SidecarServerPort represents the port on which http server will run
	SidecarServerPort = constants.SidecarServerPort
	// SidecarServerProbePath the probe path
	SidecarServerProbePath = constants.SidecarServerProbePath

	// ExporterPort is the port that metrics will be exported
	ExporterPort = constants.ExporterPort
	//ExporterPortName the name of the metrics exporter port
	ExporterPortName = "prometheus"
	// ExporterPath is the path on which metrics are expose
	ExporterPath = constants.ExporterPath

	// ConfVolumeMountPath is the path where mysql configs will be mounted
	ConfVolumeMountPath = constants.ConfVolumeMountPath
	// DataVolumeMountPath is the path to mysql data
	DataVolumeMountPath = constants.DataVolumeMountPath
	// TmpfsVolumeMountPath is the path for the tmpfs mount
	TmpfsVolumeMountPath = constants.TmpfsVolumeMountPath

	// ConfMapVolumeMountPath represents the temp config mount path in init containers
	ConfMapVolumeMountPath = constants.ConfMapVolumeMountPath
	// ConfDPath is the path to extra mysql configs dir
	ConfDPath = constants.ConfDPath
)

TODO: make those consts private and move them in the file where are used.

Variables

View Source
var (
	// TargetPort is the mysql port that is set for headless service and should be string
	TargetPort = intstr.FromInt(MysqlPort)

	// ExporterTargetPort is the port for the exporter
	ExporterTargetPort = intstr.FromInt(ExporterPort)
)

Functions

func IsPodNotFound added in v0.2.1

func IsPodNotFound(err error) bool

IsPodNotFound check if it's a PodNotFound error

func NewConfigMapSyncer

func NewConfigMapSyncer(c client.Client, scheme *runtime.Scheme, cluster *mysqlcluster.MysqlCluster) syncer.Interface

NewConfigMapSyncer returns config map syncer

func NewError added in v0.2.1

func NewError(code SyncErrCode, syncer, details string) error

NewError returns a syncer error

func NewHeadlessSVCSyncer

func NewHeadlessSVCSyncer(c client.Client, scheme *runtime.Scheme, cluster *mysqlcluster.MysqlCluster) syncer.Interface

NewHeadlessSVCSyncer returns a service syncer

func NewHealthyReplicasSVCSyncer added in v0.4.0

func NewHealthyReplicasSVCSyncer(c client.Client, scheme *runtime.Scheme, cluster *mysqlcluster.MysqlCluster) syncer.Interface

NewHealthyReplicasSVCSyncer returns a service syncer for healthy replicas service

func NewHealthySVCSyncer

func NewHealthySVCSyncer(c client.Client, scheme *runtime.Scheme, cluster *mysqlcluster.MysqlCluster) syncer.Interface

NewHealthySVCSyncer returns a service syncer

func NewMasterSVCSyncer

func NewMasterSVCSyncer(c client.Client, scheme *runtime.Scheme, cluster *mysqlcluster.MysqlCluster) syncer.Interface

NewMasterSVCSyncer returns a service syncer for master service

func NewOperatedSecretSyncer added in v0.3.0

func NewOperatedSecretSyncer(c client.Client, scheme *runtime.Scheme, cluster *mysqlcluster.MysqlCluster, opt *options.Options) syncer.Interface

NewOperatedSecretSyncer returns secret syncer

func NewPDBSyncer

func NewPDBSyncer(c client.Client, scheme *runtime.Scheme, cluster *mysqlcluster.MysqlCluster) syncer.Interface

NewPDBSyncer returns the syncer for pdb

func NewPodNotFoundError added in v0.2.1

func NewPodNotFoundError() error

NewPodNotFoundError returns a PodNotFound error

func NewPodSyncer

func NewPodSyncer(c client.Client, scheme *runtime.Scheme, cluster *mysqlcluster.MysqlCluster, host string) syncer.Interface

NewPodSyncer returns the syncer for pod

func NewSecretSyncer

func NewSecretSyncer(c client.Client, scheme *runtime.Scheme, cluster *mysqlcluster.MysqlCluster, opt *options.Options) syncer.Interface

NewSecretSyncer returns secret syncer nolint: gocyclo TODO: this syncer is not needed anymore and can be removed in future version (v0.4)

func NewStatefulSetSyncer

func NewStatefulSetSyncer(c client.Client, scheme *runtime.Scheme, cluster *mysqlcluster.MysqlCluster, cmRev, sctRev string, opt *options.Options) syncer.Interface

NewStatefulSetSyncer returns a syncer for stateful set

Types

type SyncErrCode added in v0.2.1

type SyncErrCode int

SyncErrCode is the error code

const (
	// PodNotFound represents the error when pod is not found
	PodNotFound SyncErrCode = iota
)

type SyncError added in v0.2.1

type SyncError struct {
	// contains filtered or unexported fields
}

SyncError is the error type for pod syncer

func (*SyncError) Error added in v0.2.1

func (e *SyncError) Error() string

Jump to

Keyboard shortcuts

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