component

package
v1.4.1 Latest Latest
Warning

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

Go to latest
Published: Feb 22, 2023 License: Apache-2.0 Imports: 30 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// TransLeaderBeginTime is the key of trans Leader begin time
	TransLeaderBeginTime = "transLeaderBeginTime"
	// TransLeaderTimeout is the timeout limit of trans leader
	TransLeaderTimeout = 30 * time.Minute
)
View Source
const (
	InPlaceGracePeriodSeconds = 60
)

Variables

This section is empty.

Functions

func PvcGc

func PvcGc(cli client.Client, namespace, clusterName string) error

func PvcMark

func PvcMark(pvcClient kube.PersistentVolumeClaim, component v1alpha1.NebulaClusterComponentter, oldReplicas, newReplicas int32) error

Types

type FakeGraphdCluster

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

func NewFakeGraphdCluster

func NewFakeGraphdCluster() *FakeGraphdCluster

func (*FakeGraphdCluster) Reconcile

func (f *FakeGraphdCluster) Reconcile(_ *v1alpha1.NebulaCluster) error

func (*FakeGraphdCluster) SetReconcileError

func (f *FakeGraphdCluster) SetReconcileError(err error)

type FakeMetadCluster

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

func NewFakeMetadCluster

func NewFakeMetadCluster() *FakeMetadCluster

func (*FakeMetadCluster) Reconcile

func (f *FakeMetadCluster) Reconcile(_ *v1alpha1.NebulaCluster) error

func (*FakeMetadCluster) SetReconcileError

func (f *FakeMetadCluster) SetReconcileError(err error)

type FakeStoragedCluster

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

func NewFakeStoragedCluster

func NewFakeStoragedCluster() *FakeStoragedCluster

func (*FakeStoragedCluster) Reconcile

func (*FakeStoragedCluster) SetReconcileError

func (f *FakeStoragedCluster) SetReconcileError(err error)

type ReconcileManager

type ReconcileManager interface {
	// Reconcile reconciles the cluster to desired state
	Reconcile(cluster *v1alpha1.NebulaCluster) error
}

func NewGraphdCluster

func NewGraphdCluster(
	clientSet kube.ClientSet,
	dm discovery.Interface,
	um UpdateManager,
	enableEvenPodsSpread bool) ReconcileManager

func NewMetadCluster

func NewMetadCluster(
	clientSet kube.ClientSet,
	dm discovery.Interface,
	um UpdateManager,
	enableEvenPodsSpread bool) ReconcileManager

func NewNebulaExporter added in v1.4.1

func NewNebulaExporter(clientSet kube.ClientSet) ReconcileManager

func NewStoragedCluster

func NewStoragedCluster(
	clientSet kube.ClientSet,
	dm discovery.Interface,
	sm ScaleManager,
	um UpdateManager,
	enableEvenPodsSpread bool) ReconcileManager

type ScaleManager

type ScaleManager interface {
	// Scale scales the cluster
	Scale(nc *v1alpha1.NebulaCluster, old, new *unstructured.Unstructured) error
	// ScaleIn scales in the cluster
	ScaleIn(nc *v1alpha1.NebulaCluster, oldReplicas, newReplicas int32) error
	// ScaleOut scales out the cluster
	ScaleOut(nc *v1alpha1.NebulaCluster) error
}

func NewStorageScaler

func NewStorageScaler(cli client.Client, clientSet kube.ClientSet) ScaleManager

type UpdateManager added in v0.9.0

type UpdateManager interface {
	// Update updates the cluster, as NebulaGraph doesn't support hot upgrade, the image tag remain unchanged
	Update(nc *v1alpha1.NebulaCluster, old, new *unstructured.Unstructured, gvk schema.GroupVersionKind) error
}

func NewGraphdUpdater added in v0.9.0

func NewGraphdUpdater(podClient kube.Pod) UpdateManager

func NewMetadUpdater added in v0.9.0

func NewMetadUpdater(podClient kube.Pod) UpdateManager

func NewStoragedUpdater added in v0.9.0

func NewStoragedUpdater(cli client.Client, clientSet kube.ClientSet) UpdateManager

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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