Documentation ¶
Index ¶
Constants ¶
View Source
const ( // ComponentPhaseTransition the event reason indicates that the component transits to a new phase. ComponentPhaseTransition = "ComponentPhaseTransition" // PodContainerFailedTimeout the timeout for container of pod failures, the component phase will be set to Failed/Abnormal after this time. PodContainerFailedTimeout = 10 * time.Second // PodScheduledFailedTimeout timeout for scheduling failure. PodScheduledFailedTimeout = 30 * time.Second )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Component ¶
type Component interface { GetName() string GetNamespace() string GetClusterName() string GetDefinitionName() string GetWorkloadType() appsv1alpha1.WorkloadType GetCluster() *appsv1alpha1.Cluster GetClusterVersion() *appsv1alpha1.ClusterVersion GetSynthesizedComponent() *component.SynthesizedComponent GetConsensusSpec() *appsv1alpha1.ConsensusSetSpec GetMatchingLabels() client.MatchingLabels GetPhase() appsv1alpha1.ClusterComponentPhase // GetBuiltObjects returns all objects that will be created by this component GetBuiltObjects(reqCtx intctrlutil.RequestCtx, cli client.Client) ([]client.Object, error) Create(reqCtx intctrlutil.RequestCtx, cli client.Client) error Delete(reqCtx intctrlutil.RequestCtx, cli client.Client) error Update(reqCtx intctrlutil.RequestCtx, cli client.Client) error Status(reqCtx intctrlutil.RequestCtx, cli client.Client) error Restart(reqCtx intctrlutil.RequestCtx, cli client.Client) error ExpandVolume(reqCtx intctrlutil.RequestCtx, cli client.Client) error HorizontalScale(reqCtx intctrlutil.RequestCtx, cli client.Client) error // TODO(impl): impl-related, replace them with component workload SetWorkload(obj client.Object, action *ictrltypes.LifecycleAction, parent *ictrltypes.LifecycleVertex) AddResource(obj client.Object, action *ictrltypes.LifecycleAction, parent *ictrltypes.LifecycleVertex) *ictrltypes.LifecycleVertex }
type ComponentWorkload ¶
type ComponentWorkload interface{}
Click to show internal directories.
Click to hide internal directories.