manager

package
v0.5.5 Latest Latest
Warning

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

Go to latest
Published: Nov 7, 2023 License: Apache-2.0 Imports: 32 Imported by: 0

Documentation

Index

Constants

View Source
const (
	RisingWaveAction_SyncMetaService                                              = "SyncMetaService"
	RisingWaveAction_SyncMetaStatefulSets                                         = "SyncMetaStatefulSets"
	RisingWaveAction_SyncMetaAdvancedStatefulSets                                 = "SyncMetaAdvancedStatefulSets"
	RisingWaveAction_WaitBeforeMetaServiceIsAvailable                             = "WaitBeforeMetaServiceIsAvailable"
	RisingWaveAction_WaitBeforeMetaStatefulSetsReady                              = "WaitBeforeMetaStatefulSetsReady"
	RisingWaveAction_WaitBeforeMetaAdvancedStatefulSetsReady                      = "WaitBeforeMetaAdvancedStatefulSetsReady"
	RisingWaveAction_SyncFrontendService                                          = "SyncFrontendService"
	RisingWaveAction_SyncFrontendDeployments                                      = "SyncFrontendDeployments"
	RisingWaveAction_SyncFrontendCloneSets                                        = "SyncFrontendCloneSets"
	RisingWaveAction_WaitBeforeFrontendDeploymentsReady                           = "WaitBeforeFrontendDeploymentsReady"
	RisingWaveAction_WaitBeforeFrontendCloneSetsReady                             = "WaitBeforeFrontendCloneSetsReady"
	RisingWaveAction_SyncComputeService                                           = "SyncComputeService"
	RisingWaveAction_SyncComputeStatefulSets                                      = "SyncComputeStatefulSets"
	RisingWaveAction_SyncComputeAdvancedStatefulSets                              = "SyncComputeAdvancedStatefulSets"
	RisingWaveAction_WaitBeforeComputeStatefulSetsReady                           = "WaitBeforeComputeStatefulSetsReady"
	RisingWaveAction_WaitBeforeComputeAdvancedStatefulSetsReady                   = "WaitBeforeComputeAdvancedStatefulSetsReady"
	RisingWaveAction_SyncCompactorService                                         = "SyncCompactorService"
	RisingWaveAction_SyncCompactorDeployments                                     = "SyncCompactorDeployments"
	RisingWaveAction_SyncCompactorCloneSets                                       = "SyncCompactorCloneSets"
	RisingWaveAction_WaitBeforeCompactorDeploymentsReady                          = "WaitBeforeCompactorDeploymentsReady"
	RisingWaveAction_WaitBeforeCompactorCloneSetsReady                            = "WaitBeforeCompactorCloneSetsReady"
	RisingWaveAction_SyncConnectorService                                         = "SyncConnectorService"
	RisingWaveAction_SyncConnectorDeployments                                     = "SyncConnectorDeployments"
	RisingWaveAction_SyncConnectorCloneSets                                       = "SyncConnectorCloneSets"
	RisingWaveAction_WaitBeforeConnectorDeploymentsReady                          = "WaitBeforeConnectorDeploymentsReady"
	RisingWaveAction_WaitBeforeConnectorCloneSetsReady                            = "WaitBeforeConnectorCloneSetsReady"
	RisingWaveAction_SyncConfigConfigMap                                          = "SyncConfigConfigMap"
	RisingWaveAction_SyncStandaloneService                                        = "SyncStandaloneService"
	RisingWaveAction_SyncStandaloneStatefulSet                                    = "SyncStandaloneStatefulSet"
	RisingWaveAction_SyncStandaloneAdvancedStatefulSet                            = "SyncStandaloneAdvancedStatefulSet"
	RisingWaveAction_WaitBeforeStandaloneStatefulSetReady                         = "WaitBeforeStandaloneStatefulSetReady"
	RisingWaveAction_WaitBeforeStandaloneAdvancedStatefulSetReady                 = "WaitBeforeStandaloneAdvancedStatefulSetReady"
	RisingWaveAction_SyncServiceMonitor                                           = "SyncServiceMonitor"
	RisingWaveAction_CollectRunningStatisticsAndSyncStatus                        = "CollectRunningStatisticsAndSyncStatus"
	RisingWaveAction_CollectOpenKruiseRunningStatisticsAndSyncStatus              = "CollectOpenKruiseRunningStatisticsAndSyncStatus"
	RisingWaveAction_CollectRunningStatisticsAndSyncStatusForStandalone           = "CollectRunningStatisticsAndSyncStatusForStandalone"
	RisingWaveAction_CollectOpenKruiseRunningStatisticsAndSyncStatusForStandalone = "CollectOpenKruiseRunningStatisticsAndSyncStatusForStandalone"
)

Pre-defined actions in RisingWaveControllerManager.

View Source
const (
	RisingWaveScaleViewAction_GrabOrUpdateScaleViewLock             = "GrabOrUpdateScaleViewLock"
	RisingWaveScaleViewAction_SyncGroupReplicasToRisingWave         = "SyncGroupReplicasToRisingWave"
	RisingWaveScaleViewAction_SyncGroupReplicasStatusFromRisingWave = "SyncGroupReplicasStatusFromRisingWave"
	RisingWaveScaleViewAction_UpdateScaleViewStatus                 = "UpdateScaleViewStatus"
)

Pre-defined actions in RisingWaveScaleViewControllerManager.

Variables

This section is empty.

Functions

This section is empty.

Types

type RisingWaveControllerManager

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

RisingWaveControllerManager encapsulates the states and actions used by RisingWaveController.

func NewRisingWaveControllerManager

NewRisingWaveControllerManager returns a new RisingWaveControllerManager with given state and implementation.

func (*RisingWaveControllerManager) CollectOpenKruiseRunningStatisticsAndSyncStatus added in v0.2.4

func (m *RisingWaveControllerManager) CollectOpenKruiseRunningStatisticsAndSyncStatus() ctrlkit.Action

CollectOpenKruiseRunningStatisticsAndSyncStatus generates the action of "CollectOpenKruiseRunningStatisticsAndSyncStatus".

func (*RisingWaveControllerManager) CollectOpenKruiseRunningStatisticsAndSyncStatusForStandalone added in v0.5.4

func (m *RisingWaveControllerManager) CollectOpenKruiseRunningStatisticsAndSyncStatusForStandalone() ctrlkit.Action

CollectOpenKruiseRunningStatisticsAndSyncStatusForStandalone generates the action of "CollectOpenKruiseRunningStatisticsAndSyncStatusForStandalone".

func (*RisingWaveControllerManager) CollectRunningStatisticsAndSyncStatus

func (m *RisingWaveControllerManager) CollectRunningStatisticsAndSyncStatus() ctrlkit.Action

CollectRunningStatisticsAndSyncStatus generates the action of "CollectRunningStatisticsAndSyncStatus".

func (*RisingWaveControllerManager) CollectRunningStatisticsAndSyncStatusForStandalone added in v0.5.4

func (m *RisingWaveControllerManager) CollectRunningStatisticsAndSyncStatusForStandalone() ctrlkit.Action

CollectRunningStatisticsAndSyncStatusForStandalone generates the action of "CollectRunningStatisticsAndSyncStatusForStandalone".

func (*RisingWaveControllerManager) NewAction

func (m *RisingWaveControllerManager) NewAction(description string, f func(context.Context, logr.Logger) (ctrl.Result, error)) ctrlkit.Action

NewAction returns a new action controlled by the manager.

func (*RisingWaveControllerManager) SyncCompactorCloneSets added in v0.2.4

func (m *RisingWaveControllerManager) SyncCompactorCloneSets() ctrlkit.Action

SyncCompactorCloneSets generates the action of "SyncCompactorCloneSets".

func (*RisingWaveControllerManager) SyncCompactorDeployments

func (m *RisingWaveControllerManager) SyncCompactorDeployments() ctrlkit.Action

SyncCompactorDeployments generates the action of "SyncCompactorDeployments".

func (*RisingWaveControllerManager) SyncCompactorService

func (m *RisingWaveControllerManager) SyncCompactorService() ctrlkit.Action

SyncCompactorService generates the action of "SyncCompactorService".

func (*RisingWaveControllerManager) SyncComputeAdvancedStatefulSets added in v0.2.4

func (m *RisingWaveControllerManager) SyncComputeAdvancedStatefulSets() ctrlkit.Action

SyncComputeAdvancedStatefulSets generates the action of "SyncComputeAdvancedStatefulSets".

func (*RisingWaveControllerManager) SyncComputeService

func (m *RisingWaveControllerManager) SyncComputeService() ctrlkit.Action

SyncComputeService generates the action of "SyncComputeService".

func (*RisingWaveControllerManager) SyncComputeStatefulSets

func (m *RisingWaveControllerManager) SyncComputeStatefulSets() ctrlkit.Action

SyncComputeStatefulSets generates the action of "SyncComputeStatefulSets".

func (*RisingWaveControllerManager) SyncConfigConfigMap

func (m *RisingWaveControllerManager) SyncConfigConfigMap() ctrlkit.Action

SyncConfigConfigMap generates the action of "SyncConfigConfigMap".

func (*RisingWaveControllerManager) SyncConnectorCloneSets added in v0.2.6

func (m *RisingWaveControllerManager) SyncConnectorCloneSets() ctrlkit.Action

SyncConnectorCloneSets generates the action of "SyncConnectorCloneSets".

func (*RisingWaveControllerManager) SyncConnectorDeployments added in v0.2.6

func (m *RisingWaveControllerManager) SyncConnectorDeployments() ctrlkit.Action

SyncConnectorDeployments generates the action of "SyncConnectorDeployments".

func (*RisingWaveControllerManager) SyncConnectorService added in v0.2.6

func (m *RisingWaveControllerManager) SyncConnectorService() ctrlkit.Action

SyncConnectorService generates the action of "SyncConnectorService".

func (*RisingWaveControllerManager) SyncFrontendCloneSets added in v0.2.4

func (m *RisingWaveControllerManager) SyncFrontendCloneSets() ctrlkit.Action

SyncFrontendCloneSets generates the action of "SyncFrontendCloneSets".

func (*RisingWaveControllerManager) SyncFrontendDeployments

func (m *RisingWaveControllerManager) SyncFrontendDeployments() ctrlkit.Action

SyncFrontendDeployments generates the action of "SyncFrontendDeployments".

func (*RisingWaveControllerManager) SyncFrontendService

func (m *RisingWaveControllerManager) SyncFrontendService() ctrlkit.Action

SyncFrontendService generates the action of "SyncFrontendService".

func (*RisingWaveControllerManager) SyncMetaAdvancedStatefulSets added in v0.2.5

func (m *RisingWaveControllerManager) SyncMetaAdvancedStatefulSets() ctrlkit.Action

SyncMetaAdvancedStatefulSets generates the action of "SyncMetaAdvancedStatefulSets".

func (*RisingWaveControllerManager) SyncMetaService

func (m *RisingWaveControllerManager) SyncMetaService() ctrlkit.Action

SyncMetaService generates the action of "SyncMetaService".

func (*RisingWaveControllerManager) SyncMetaStatefulSets added in v0.2.5

func (m *RisingWaveControllerManager) SyncMetaStatefulSets() ctrlkit.Action

SyncMetaStatefulSets generates the action of "SyncMetaStatefulSets".

func (*RisingWaveControllerManager) SyncServiceMonitor

func (m *RisingWaveControllerManager) SyncServiceMonitor() ctrlkit.Action

SyncServiceMonitor generates the action of "SyncServiceMonitor".

func (*RisingWaveControllerManager) SyncStandaloneAdvancedStatefulSet added in v0.5.4

func (m *RisingWaveControllerManager) SyncStandaloneAdvancedStatefulSet() ctrlkit.Action

SyncStandaloneAdvancedStatefulSet generates the action of "SyncStandaloneAdvancedStatefulSet".

func (*RisingWaveControllerManager) SyncStandaloneService added in v0.5.4

func (m *RisingWaveControllerManager) SyncStandaloneService() ctrlkit.Action

SyncStandaloneService generates the action of "SyncStandaloneService".

func (*RisingWaveControllerManager) SyncStandaloneStatefulSet added in v0.5.4

func (m *RisingWaveControllerManager) SyncStandaloneStatefulSet() ctrlkit.Action

SyncStandaloneStatefulSet generates the action of "SyncStandaloneStatefulSet".

func (*RisingWaveControllerManager) WaitBeforeCompactorCloneSetsReady added in v0.2.4

func (m *RisingWaveControllerManager) WaitBeforeCompactorCloneSetsReady() ctrlkit.Action

WaitBeforeCompactorCloneSetsReady generates the action of "WaitBeforeCompactorCloneSetsReady".

func (*RisingWaveControllerManager) WaitBeforeCompactorDeploymentsReady

func (m *RisingWaveControllerManager) WaitBeforeCompactorDeploymentsReady() ctrlkit.Action

WaitBeforeCompactorDeploymentsReady generates the action of "WaitBeforeCompactorDeploymentsReady".

func (*RisingWaveControllerManager) WaitBeforeComputeAdvancedStatefulSetsReady added in v0.2.4

func (m *RisingWaveControllerManager) WaitBeforeComputeAdvancedStatefulSetsReady() ctrlkit.Action

WaitBeforeComputeAdvancedStatefulSetsReady generates the action of "WaitBeforeComputeAdvancedStatefulSetsReady".

func (*RisingWaveControllerManager) WaitBeforeComputeStatefulSetsReady

func (m *RisingWaveControllerManager) WaitBeforeComputeStatefulSetsReady() ctrlkit.Action

WaitBeforeComputeStatefulSetsReady generates the action of "WaitBeforeComputeStatefulSetsReady".

func (*RisingWaveControllerManager) WaitBeforeConnectorCloneSetsReady added in v0.2.6

func (m *RisingWaveControllerManager) WaitBeforeConnectorCloneSetsReady() ctrlkit.Action

WaitBeforeConnectorCloneSetsReady generates the action of "WaitBeforeConnectorCloneSetsReady".

func (*RisingWaveControllerManager) WaitBeforeConnectorDeploymentsReady added in v0.2.6

func (m *RisingWaveControllerManager) WaitBeforeConnectorDeploymentsReady() ctrlkit.Action

WaitBeforeConnectorDeploymentsReady generates the action of "WaitBeforeConnectorDeploymentsReady".

func (*RisingWaveControllerManager) WaitBeforeFrontendCloneSetsReady added in v0.2.4

func (m *RisingWaveControllerManager) WaitBeforeFrontendCloneSetsReady() ctrlkit.Action

WaitBeforeFrontendCloneSetsReady generates the action of "WaitBeforeFrontendCloneSetsReady".

func (*RisingWaveControllerManager) WaitBeforeFrontendDeploymentsReady

func (m *RisingWaveControllerManager) WaitBeforeFrontendDeploymentsReady() ctrlkit.Action

WaitBeforeFrontendDeploymentsReady generates the action of "WaitBeforeFrontendDeploymentsReady".

func (*RisingWaveControllerManager) WaitBeforeMetaAdvancedStatefulSetsReady added in v0.2.5

func (m *RisingWaveControllerManager) WaitBeforeMetaAdvancedStatefulSetsReady() ctrlkit.Action

WaitBeforeMetaAdvancedStatefulSetsReady generates the action of "WaitBeforeMetaAdvancedStatefulSetsReady".

func (*RisingWaveControllerManager) WaitBeforeMetaServiceIsAvailable

func (m *RisingWaveControllerManager) WaitBeforeMetaServiceIsAvailable() ctrlkit.Action

WaitBeforeMetaServiceIsAvailable generates the action of "WaitBeforeMetaServiceIsAvailable".

func (*RisingWaveControllerManager) WaitBeforeMetaStatefulSetsReady added in v0.2.5

func (m *RisingWaveControllerManager) WaitBeforeMetaStatefulSetsReady() ctrlkit.Action

WaitBeforeMetaStatefulSetsReady generates the action of "WaitBeforeMetaStatefulSetsReady".

func (*RisingWaveControllerManager) WaitBeforeStandaloneAdvancedStatefulSetReady added in v0.5.4

func (m *RisingWaveControllerManager) WaitBeforeStandaloneAdvancedStatefulSetReady() ctrlkit.Action

WaitBeforeStandaloneAdvancedStatefulSetReady generates the action of "WaitBeforeStandaloneAdvancedStatefulSetReady".

func (*RisingWaveControllerManager) WaitBeforeStandaloneStatefulSetReady added in v0.5.4

func (m *RisingWaveControllerManager) WaitBeforeStandaloneStatefulSetReady() ctrlkit.Action

WaitBeforeStandaloneStatefulSetReady generates the action of "WaitBeforeStandaloneStatefulSetReady".

type RisingWaveControllerManagerImpl

type RisingWaveControllerManagerImpl interface {
	// SyncMetaService creates or updates the service for meta nodes.
	SyncMetaService(ctx context.Context, logger logr.Logger, metaService *corev1.Service) (ctrl.Result, error)

	// SyncMetaStatefulSets creates or updates the StatefulSets for meta nodes.
	SyncMetaStatefulSets(ctx context.Context, logger logr.Logger, metaStatefulSets []appsv1.StatefulSet) (ctrl.Result, error)

	// SyncMetaAdvancedStatefulSets creates or updates the CloneSets for meta nodes.
	SyncMetaAdvancedStatefulSets(ctx context.Context, logger logr.Logger, metaAdvancedStatefulSets []appsv1beta1.StatefulSet) (ctrl.Result, error)

	// WaitBeforeMetaServiceIsAvailable waits (aborts the workflow) before the meta service is available.
	WaitBeforeMetaServiceIsAvailable(ctx context.Context, logger logr.Logger, metaService *corev1.Service) (ctrl.Result, error)

	// WaitBeforeMetaStatefulSetsReady waits (aborts the workflow) before the meta StatefulSets are ready.
	WaitBeforeMetaStatefulSetsReady(ctx context.Context, logger logr.Logger, metaStatefulSets []appsv1.StatefulSet) (ctrl.Result, error)

	// WaitBeforeMetaAdvancedStatefulSetsReady waits (aborts the workflow) before the meta advanced StatefulSets are ready.
	WaitBeforeMetaAdvancedStatefulSetsReady(ctx context.Context, logger logr.Logger, metaAdvancedStatefulSets []appsv1beta1.StatefulSet) (ctrl.Result, error)

	// SyncFrontendService creates or updates the service for frontend nodes.
	SyncFrontendService(ctx context.Context, logger logr.Logger, frontendService *corev1.Service) (ctrl.Result, error)

	// SyncFrontendDeployments creates or updates the Deployments for frontend nodes.
	SyncFrontendDeployments(ctx context.Context, logger logr.Logger, frontendDeployments []appsv1.Deployment) (ctrl.Result, error)

	// SyncFrontendCloneSets creates or updates the Deployments for frontend nodes.
	SyncFrontendCloneSets(ctx context.Context, logger logr.Logger, frontendCloneSets []appsv1alpha1.CloneSet) (ctrl.Result, error)

	// WaitBeforeFrontendDeploymentsReady waits (aborts the workflow) before the frontend Deployments are ready.
	WaitBeforeFrontendDeploymentsReady(ctx context.Context, logger logr.Logger, frontendDeployments []appsv1.Deployment) (ctrl.Result, error)

	// WaitBeforeFrontendCloneSetsReady waits (aborts the workflow) before the frontend CloneSets are ready.
	WaitBeforeFrontendCloneSetsReady(ctx context.Context, logger logr.Logger, frontendCloneSets []appsv1alpha1.CloneSet) (ctrl.Result, error)

	// SyncComputeService creates or updates the service for compute nodes.
	SyncComputeService(ctx context.Context, logger logr.Logger, computeService *corev1.Service) (ctrl.Result, error)

	// SyncComputeStatefulSets creates or updates the StatefulSets for compute nodes.
	SyncComputeStatefulSets(ctx context.Context, logger logr.Logger, computeStatefulSets []appsv1.StatefulSet) (ctrl.Result, error)

	// SyncComputeAdvancedStatefulSets creates or updates the StatefulSets for compute nodes.
	SyncComputeAdvancedStatefulSets(ctx context.Context, logger logr.Logger, computeAdvancedStatefulSets []appsv1beta1.StatefulSet) (ctrl.Result, error)

	// WaitBeforeComputeStatefulSetsReady waits (aborts the workflow) before the compute StatefulSets are ready.
	WaitBeforeComputeStatefulSetsReady(ctx context.Context, logger logr.Logger, computeStatefulSets []appsv1.StatefulSet) (ctrl.Result, error)

	// WaitBeforeComputeStatefulSetsReady waits (aborts the workflow) before the compute advanced StatefulSets are ready.
	WaitBeforeComputeAdvancedStatefulSetsReady(ctx context.Context, logger logr.Logger, computeAdvancedStatefulSets []appsv1beta1.StatefulSet) (ctrl.Result, error)

	// SyncCompactorService creates or updates the service for compactor nodes.
	SyncCompactorService(ctx context.Context, logger logr.Logger, compactorService *corev1.Service) (ctrl.Result, error)

	// SyncCompactorDeployments creates or updates the Deployments for compactor nodes.
	SyncCompactorDeployments(ctx context.Context, logger logr.Logger, compactorDeployments []appsv1.Deployment) (ctrl.Result, error)

	// SyncCompactorCloneSets creates or updates the Deployments for compactor nodes.
	SyncCompactorCloneSets(ctx context.Context, logger logr.Logger, compactorCloneSets []appsv1alpha1.CloneSet) (ctrl.Result, error)

	// WaitBeforeCompactorDeploymentsReady waits (aborts the workflow) before the compactor Deployments are ready.
	WaitBeforeCompactorDeploymentsReady(ctx context.Context, logger logr.Logger, compactorDeployments []appsv1.Deployment) (ctrl.Result, error)

	// WaitBeforeCompactorDeploymentsReady waits (aborts the workflow) before the compactor CloneSets are ready.
	WaitBeforeCompactorCloneSetsReady(ctx context.Context, logger logr.Logger, compactorCloneSets []appsv1alpha1.CloneSet) (ctrl.Result, error)

	// SyncConnectorService creates or updates the service for connector nodes.
	SyncConnectorService(ctx context.Context, logger logr.Logger, connectorService *corev1.Service) (ctrl.Result, error)

	// SyncConnectorDeployments creates or updates the Deployments for connector nodes.
	SyncConnectorDeployments(ctx context.Context, logger logr.Logger, connectorDeployments []appsv1.Deployment) (ctrl.Result, error)

	// SyncConnectorCloneSets creates or updates the Deployments for connector nodes.
	SyncConnectorCloneSets(ctx context.Context, logger logr.Logger, connectorCloneSets []appsv1alpha1.CloneSet) (ctrl.Result, error)

	// WaitBeforeConnectorDeploymentsReady waits (aborts the workflow) before the connector Deployments are ready.
	WaitBeforeConnectorDeploymentsReady(ctx context.Context, logger logr.Logger, connectorDeployments []appsv1.Deployment) (ctrl.Result, error)

	// WaitBeforeConnectorDeploymentsReady waits (aborts the workflow) before the connector CloneSets are ready.
	WaitBeforeConnectorCloneSetsReady(ctx context.Context, logger logr.Logger, connectorCloneSets []appsv1alpha1.CloneSet) (ctrl.Result, error)

	// SyncConfigConfigMap creates or updates the configmap for RisingWave configs.
	SyncConfigConfigMap(ctx context.Context, logger logr.Logger, configConfigMap *corev1.ConfigMap) (ctrl.Result, error)

	// SyncStandaloneService creates or updates the service for standalone RisingWave.
	SyncStandaloneService(ctx context.Context, logger logr.Logger, standaloneService *corev1.Service) (ctrl.Result, error)

	// SyncStandaloneStatefulSet creates or updates the StatefulSet for standalone RisingWave.
	SyncStandaloneStatefulSet(ctx context.Context, logger logr.Logger, standaloneStatefulSet *appsv1.StatefulSet) (ctrl.Result, error)

	// SyncStandaloneAdvancedStatefulSet creates or updates the advanced StatefulSet for standalone RisingWave.
	SyncStandaloneAdvancedStatefulSet(ctx context.Context, logger logr.Logger, standaloneAdvancedStatefulSet *appsv1beta1.StatefulSet) (ctrl.Result, error)

	// WaitBeforeStandaloneStatefulSetReady waits (aborts the workflow) before the standalone StatefulSet is ready.
	WaitBeforeStandaloneStatefulSetReady(ctx context.Context, logger logr.Logger, standaloneStatefulSet *appsv1.StatefulSet) (ctrl.Result, error)

	// WaitBeforeStandaloneAdvancedStatefulSetReady waits (aborts the workflow) before the standalone advanced StatefulSet is ready.
	WaitBeforeStandaloneAdvancedStatefulSetReady(ctx context.Context, logger logr.Logger, standaloneAdvancedStatefulSet *appsv1beta1.StatefulSet) (ctrl.Result, error)

	// SyncServiceMonitor creates or updates the service monitor for RisingWave.
	SyncServiceMonitor(ctx context.Context, logger logr.Logger, serviceMonitor *monitoringv1.ServiceMonitor) (ctrl.Result, error)

	// CollectRunningStatisticsAndSyncStatus collects running statistics and sync them into the status.
	CollectRunningStatisticsAndSyncStatus(ctx context.Context, logger logr.Logger, frontendService *corev1.Service, metaService *corev1.Service, computeService *corev1.Service, compactorService *corev1.Service, connectorService *corev1.Service, metaStatefulSets []appsv1.StatefulSet, frontendDeployments []appsv1.Deployment, computeStatefulSets []appsv1.StatefulSet, compactorDeployments []appsv1.Deployment, connectorDeployments []appsv1.Deployment, configConfigMap *corev1.ConfigMap) (ctrl.Result, error)

	CollectOpenKruiseRunningStatisticsAndSyncStatus(ctx context.Context, logger logr.Logger, frontendService *corev1.Service, metaService *corev1.Service, computeService *corev1.Service, compactorService *corev1.Service, connectorService *corev1.Service, metaAdvancedStatefulSets []appsv1beta1.StatefulSet, frontendCloneSets []appsv1alpha1.CloneSet, computeAdvancedStatefulSets []appsv1beta1.StatefulSet, compactorCloneSets []appsv1alpha1.CloneSet, connectorCloneSets []appsv1alpha1.CloneSet, configConfigMap *corev1.ConfigMap) (ctrl.Result, error)

	// CollectRunningStatisticsAndSyncStatusForStandalone collects running statistics and sync them into the status.
	CollectRunningStatisticsAndSyncStatusForStandalone(ctx context.Context, logger logr.Logger, standaloneService *corev1.Service, standaloneStatefulSet *appsv1.StatefulSet, configConfigMap *corev1.ConfigMap) (ctrl.Result, error)

	CollectOpenKruiseRunningStatisticsAndSyncStatusForStandalone(ctx context.Context, logger logr.Logger, standaloneService *corev1.Service, standaloneAdvancedStatefulSet *appsv1beta1.StatefulSet, configConfigMap *corev1.ConfigMap) (ctrl.Result, error)
}

RisingWaveControllerManagerImpl declares the implementation interface for RisingWaveControllerManager.

func NewRisingWaveControllerManagerImpl

func NewRisingWaveControllerManagerImpl(client client.Client, risingwaveManager *object.RisingWaveManager, messageStore *event.MessageStore, forceUpdateEnabled bool, operatorVersion string) RisingWaveControllerManagerImpl

NewRisingWaveControllerManagerImpl creates an object that implements the RisingWaveControllerManagerImpl.

type RisingWaveControllerManagerOption

type RisingWaveControllerManagerOption func(*RisingWaveControllerManager)

func RisingWaveControllerManager_WithActionHook

func RisingWaveControllerManager_WithActionHook(hook ctrlkit.ActionHook) RisingWaveControllerManagerOption

type RisingWaveControllerManagerState

type RisingWaveControllerManagerState struct {
	client.Reader
	// contains filtered or unexported fields
}

RisingWaveControllerManagerState is the state manager of RisingWaveControllerManager.

func NewRisingWaveControllerManagerState

func NewRisingWaveControllerManagerState(reader client.Reader, target *risingwavev1alpha1.RisingWave) RisingWaveControllerManagerState

NewRisingWaveControllerManagerState returns a RisingWaveControllerManagerState (target is not copied).

func (*RisingWaveControllerManagerState) GetCompactorCloneSets added in v0.2.4

func (s *RisingWaveControllerManagerState) GetCompactorCloneSets(ctx context.Context) ([]appsv1alpha1.CloneSet, error)

GetCompactorCloneSets lists compactorCloneSets with the following selectors:

  • labels/risingwave/component=compactor
  • labels/risingwave/name=${target.Name}
  • owned

func (*RisingWaveControllerManagerState) GetCompactorDeployments

func (s *RisingWaveControllerManagerState) GetCompactorDeployments(ctx context.Context) ([]appsv1.Deployment, error)

GetCompactorDeployments lists compactorDeployments with the following selectors:

  • labels/risingwave/component=compactor
  • labels/risingwave/name=${target.Name}
  • owned

func (*RisingWaveControllerManagerState) GetCompactorService

func (s *RisingWaveControllerManagerState) GetCompactorService(ctx context.Context) (*corev1.Service, error)

GetCompactorService gets compactorService with name equals to ${target.Name}-compactor.

func (*RisingWaveControllerManagerState) GetComputeAdvancedStatefulSets added in v0.2.4

func (s *RisingWaveControllerManagerState) GetComputeAdvancedStatefulSets(ctx context.Context) ([]appsv1beta1.StatefulSet, error)

GetComputeAdvancedStatefulSets lists computeAdvancedStatefulSets with the following selectors:

  • labels/risingwave/component=compute
  • labels/risingwave/name=${target.Name}
  • owned

func (*RisingWaveControllerManagerState) GetComputeService

func (s *RisingWaveControllerManagerState) GetComputeService(ctx context.Context) (*corev1.Service, error)

GetComputeService gets computeService with name equals to ${target.Name}-compute.

func (*RisingWaveControllerManagerState) GetComputeStatefulSets

func (s *RisingWaveControllerManagerState) GetComputeStatefulSets(ctx context.Context) ([]appsv1.StatefulSet, error)

GetComputeStatefulSets lists computeStatefulSets with the following selectors:

  • labels/risingwave/component=compute
  • labels/risingwave/name=${target.Name}
  • owned

func (*RisingWaveControllerManagerState) GetConfigConfigMap

func (s *RisingWaveControllerManagerState) GetConfigConfigMap(ctx context.Context) (*corev1.ConfigMap, error)

GetConfigConfigMap gets configConfigMap with name equals to ${target.Name}-default-config.

func (*RisingWaveControllerManagerState) GetConnectorCloneSets added in v0.2.6

func (s *RisingWaveControllerManagerState) GetConnectorCloneSets(ctx context.Context) ([]appsv1alpha1.CloneSet, error)

GetConnectorCloneSets lists connectorCloneSets with the following selectors:

  • labels/risingwave/component=connector
  • labels/risingwave/name=${target.Name}
  • owned

func (*RisingWaveControllerManagerState) GetConnectorDeployments added in v0.2.6

func (s *RisingWaveControllerManagerState) GetConnectorDeployments(ctx context.Context) ([]appsv1.Deployment, error)

GetConnectorDeployments lists connectorDeployments with the following selectors:

  • labels/risingwave/component=connector
  • labels/risingwave/name=${target.Name}
  • owned

func (*RisingWaveControllerManagerState) GetConnectorService added in v0.2.6

func (s *RisingWaveControllerManagerState) GetConnectorService(ctx context.Context) (*corev1.Service, error)

GetConnectorService gets connectorService with name equals to ${target.Name}-connector.

func (*RisingWaveControllerManagerState) GetFrontendCloneSets added in v0.2.4

func (s *RisingWaveControllerManagerState) GetFrontendCloneSets(ctx context.Context) ([]appsv1alpha1.CloneSet, error)

GetFrontendCloneSets lists frontendCloneSets with the following selectors:

  • labels/risingwave/component=frontend
  • labels/risingwave/name=${target.Name}
  • owned

func (*RisingWaveControllerManagerState) GetFrontendDeployments

func (s *RisingWaveControllerManagerState) GetFrontendDeployments(ctx context.Context) ([]appsv1.Deployment, error)

GetFrontendDeployments lists frontendDeployments with the following selectors:

  • labels/risingwave/component=frontend
  • labels/risingwave/name=${target.Name}
  • owned

func (*RisingWaveControllerManagerState) GetFrontendService

func (s *RisingWaveControllerManagerState) GetFrontendService(ctx context.Context) (*corev1.Service, error)

GetFrontendService gets frontendService with name equals to ${target.Name}-frontend.

func (*RisingWaveControllerManagerState) GetMetaAdvancedStatefulSets added in v0.2.5

func (s *RisingWaveControllerManagerState) GetMetaAdvancedStatefulSets(ctx context.Context) ([]appsv1beta1.StatefulSet, error)

GetMetaAdvancedStatefulSets lists metaAdvancedStatefulSets with the following selectors:

  • labels/risingwave/component=meta
  • labels/risingwave/name=${target.Name}
  • owned

func (*RisingWaveControllerManagerState) GetMetaService

GetMetaService gets metaService with name equals to ${target.Name}-meta.

func (*RisingWaveControllerManagerState) GetMetaStatefulSets added in v0.2.5

func (s *RisingWaveControllerManagerState) GetMetaStatefulSets(ctx context.Context) ([]appsv1.StatefulSet, error)

GetMetaStatefulSets lists metaStatefulSets with the following selectors:

  • labels/risingwave/component=meta
  • labels/risingwave/name=${target.Name}
  • owned

func (*RisingWaveControllerManagerState) GetServiceMonitor

GetServiceMonitor gets serviceMonitor with name equals to risingwave-${target.Name}.

func (*RisingWaveControllerManagerState) GetStandaloneAdvancedStatefulSet added in v0.5.4

func (s *RisingWaveControllerManagerState) GetStandaloneAdvancedStatefulSet(ctx context.Context) (*appsv1beta1.StatefulSet, error)

GetStandaloneAdvancedStatefulSet gets standaloneAdvancedStatefulSet with name equals to ${target.Name}-standalone.

func (*RisingWaveControllerManagerState) GetStandaloneService added in v0.5.4

func (s *RisingWaveControllerManagerState) GetStandaloneService(ctx context.Context) (*corev1.Service, error)

GetStandaloneService gets standaloneService with name equals to ${target.Name}-standalone.

func (*RisingWaveControllerManagerState) GetStandaloneStatefulSet added in v0.5.4

func (s *RisingWaveControllerManagerState) GetStandaloneStatefulSet(ctx context.Context) (*appsv1.StatefulSet, error)

GetStandaloneStatefulSet gets standaloneStatefulSet with name equals to ${target.Name}-standalone.

type RisingWaveScaleViewControllerManager added in v0.2.2

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

RisingWaveScaleViewControllerManager encapsulates the states and actions used by RisingWaveScaleViewController.

func NewRisingWaveScaleViewControllerManager added in v0.2.2

NewRisingWaveScaleViewControllerManager returns a new RisingWaveScaleViewControllerManager with given state and implementation.

func (*RisingWaveScaleViewControllerManager) GrabOrUpdateScaleViewLock added in v0.2.2

func (m *RisingWaveScaleViewControllerManager) GrabOrUpdateScaleViewLock() ctrlkit.Action

GrabOrUpdateScaleViewLock generates the action of "GrabOrUpdateScaleViewLock".

func (*RisingWaveScaleViewControllerManager) NewAction added in v0.2.2

NewAction returns a new action controlled by the manager.

func (*RisingWaveScaleViewControllerManager) SyncGroupReplicasStatusFromRisingWave added in v0.2.2

func (m *RisingWaveScaleViewControllerManager) SyncGroupReplicasStatusFromRisingWave() ctrlkit.Action

SyncGroupReplicasStatusFromRisingWave generates the action of "SyncGroupReplicasStatusFromRisingWave".

func (*RisingWaveScaleViewControllerManager) SyncGroupReplicasToRisingWave added in v0.2.2

func (m *RisingWaveScaleViewControllerManager) SyncGroupReplicasToRisingWave() ctrlkit.Action

SyncGroupReplicasToRisingWave generates the action of "SyncGroupReplicasToRisingWave".

func (*RisingWaveScaleViewControllerManager) UpdateScaleViewStatus added in v0.2.2

func (m *RisingWaveScaleViewControllerManager) UpdateScaleViewStatus() ctrlkit.Action

UpdateScaleViewStatus generates the action of "UpdateScaleViewStatus".

type RisingWaveScaleViewControllerManagerImpl added in v0.2.2

type RisingWaveScaleViewControllerManagerImpl interface {
	// Grab or update the lock for the current RisingWaveScaleView.
	GrabOrUpdateScaleViewLock(ctx context.Context, logger logr.Logger, targetObj *risingwavev1alpha1.RisingWave) (ctrl.Result, error)

	// Sync the replicas of targeting groups to RisingWave's spec.
	SyncGroupReplicasToRisingWave(ctx context.Context, logger logr.Logger, targetObj *risingwavev1alpha1.RisingWave) (ctrl.Result, error)

	// Sync the replicas from RisingWave's spec.
	SyncGroupReplicasStatusFromRisingWave(ctx context.Context, logger logr.Logger, targetObj *risingwavev1alpha1.RisingWave) (ctrl.Result, error)

	// Update the status.
	UpdateScaleViewStatus(ctx context.Context, logger logr.Logger) (ctrl.Result, error)
}

RisingWaveScaleViewControllerManagerImpl declares the implementation interface for RisingWaveScaleViewControllerManager.

func NewRisingWaveScaleViewControllerManagerImpl added in v0.2.2

func NewRisingWaveScaleViewControllerManagerImpl(client client.Client, scaleView *risingwavev1alpha1.RisingWaveScaleView) RisingWaveScaleViewControllerManagerImpl

NewRisingWaveScaleViewControllerManagerImpl creates an object that implements the RisingWaveScaleViewControllerManagerImpl.

type RisingWaveScaleViewControllerManagerOption added in v0.2.2

type RisingWaveScaleViewControllerManagerOption func(*RisingWaveScaleViewControllerManager)

func RisingWaveScaleViewControllerManager_WithActionHook added in v0.2.2

func RisingWaveScaleViewControllerManager_WithActionHook(hook ctrlkit.ActionHook) RisingWaveScaleViewControllerManagerOption

type RisingWaveScaleViewControllerManagerState added in v0.2.2

type RisingWaveScaleViewControllerManagerState struct {
	client.Reader
	// contains filtered or unexported fields
}

RisingWaveScaleViewControllerManagerState is the state manager of RisingWaveScaleViewControllerManager.

func NewRisingWaveScaleViewControllerManagerState added in v0.2.2

func NewRisingWaveScaleViewControllerManagerState(reader client.Reader, target *risingwavev1alpha1.RisingWaveScaleView) RisingWaveScaleViewControllerManagerState

NewRisingWaveScaleViewControllerManagerState returns a RisingWaveScaleViewControllerManagerState (target is not copied).

func (*RisingWaveScaleViewControllerManagerState) GetTargetObj added in v0.2.2

GetTargetObj gets targetObj with name equals to ${target.Spec.TargetRef.Name}.

Jump to

Keyboard shortcuts

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