Documentation ¶
Index ¶
- func ComposeRolePriorityMap(consensusSpec *appsv1alpha1.ConsensusSetSpec) map[string]int
- func NewConsensusComponent(cli client.Client, recorder record.EventRecorder, ...) *consensusComponent
- func UpdateConsensusSetRoleLabel(cli client.Client, reqCtx intctrlutil.RequestCtx, ...) error
- type ConsensusSet
- func (r *ConsensusSet) GetPhaseWhenPodsNotReady(ctx context.Context, componentName string) (appsv1alpha1.ClusterComponentPhase, appsv1alpha1.ComponentMessageMap, error)
- func (r *ConsensusSet) GetPhaseWhenPodsReadyAndProbeTimeout(pods []*corev1.Pod) (appsv1alpha1.ClusterComponentPhase, appsv1alpha1.ComponentMessageMap)
- func (r *ConsensusSet) HandleHA(ctx context.Context, obj client.Object) ([]graph.Vertex, error)
- func (r *ConsensusSet) HandleRestart(ctx context.Context, obj client.Object) ([]graph.Vertex, error)
- func (r *ConsensusSet) HandleRoleChange(ctx context.Context, obj client.Object) ([]graph.Vertex, error)
- func (r *ConsensusSet) IsRunning(ctx context.Context, obj client.Object) (bool, error)
- func (r *ConsensusSet) PodIsAvailable(pod *corev1.Pod, minReadySeconds int32) bool
- func (r *ConsensusSet) PodsReady(ctx context.Context, obj client.Object) (bool, error)
- func (r *ConsensusSet) SetComponent(comp types.Component)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ComposeRolePriorityMap ¶
func ComposeRolePriorityMap(consensusSpec *appsv1alpha1.ConsensusSetSpec) map[string]int
ComposeRolePriorityMap generates a priority map based on roles.
func NewConsensusComponent ¶
func NewConsensusComponent(cli client.Client, recorder record.EventRecorder, cluster *appsv1alpha1.Cluster, clusterVersion *appsv1alpha1.ClusterVersion, synthesizedComponent *component.SynthesizedComponent, dag *graph.DAG) *consensusComponent
func UpdateConsensusSetRoleLabel ¶
func UpdateConsensusSetRoleLabel(cli client.Client, reqCtx intctrlutil.RequestCtx, componentDef *appsv1alpha1.ClusterComponentDefinition, pod *corev1.Pod, role string) error
UpdateConsensusSetRoleLabel updates pod role label when internal container role changed
Types ¶
type ConsensusSet ¶
func (*ConsensusSet) GetPhaseWhenPodsNotReady ¶
func (r *ConsensusSet) GetPhaseWhenPodsNotReady(ctx context.Context, componentName string) (appsv1alpha1.ClusterComponentPhase, appsv1alpha1.ComponentMessageMap, error)
func (*ConsensusSet) GetPhaseWhenPodsReadyAndProbeTimeout ¶
func (r *ConsensusSet) GetPhaseWhenPodsReadyAndProbeTimeout(pods []*corev1.Pod) (appsv1alpha1.ClusterComponentPhase, appsv1alpha1.ComponentMessageMap)
func (*ConsensusSet) HandleRestart ¶
func (*ConsensusSet) HandleRoleChange ¶
func (*ConsensusSet) PodIsAvailable ¶
func (r *ConsensusSet) PodIsAvailable(pod *corev1.Pod, minReadySeconds int32) bool
func (*ConsensusSet) SetComponent ¶
func (r *ConsensusSet) SetComponent(comp types.Component)
Click to show internal directories.
Click to hide internal directories.