Documentation
¶
Index ¶
- func CreateOrUpdateClientService(ctx context.Context, cluster *etcdaenixiov1alpha1.EtcdCluster, ...) error
- func CreateOrUpdateClusterStateConfigMap(ctx context.Context, cluster *etcdaenixiov1alpha1.EtcdCluster, ...) error
- func CreateOrUpdateHeadlessService(ctx context.Context, cluster *etcdaenixiov1alpha1.EtcdCluster, ...) error
- func CreateOrUpdatePdb(ctx context.Context, cluster *etcdaenixiov1alpha1.EtcdCluster, ...) error
- func CreateOrUpdateStatefulSet(ctx context.Context, cluster *etcdaenixiov1alpha1.EtcdCluster, ...) error
- func FillConditions(cluster *etcdaenixiov1alpha1.EtcdCluster)
- func GetClusterStateConfigMapName(cluster *etcdaenixiov1alpha1.EtcdCluster) string
- func GetCondition(cluster *etcdaenixiov1alpha1.EtcdCluster, condType string) *metav1.Condition
- func GetHeadlessServiceName(cluster *etcdaenixiov1alpha1.EtcdCluster) string
- func GetPVCName(cluster *etcdaenixiov1alpha1.EtcdCluster) string
- func GetServerProtocol(cluster *etcdaenixiov1alpha1.EtcdCluster) string
- func GetServiceName(cluster *etcdaenixiov1alpha1.EtcdCluster) string
- func NewEtcdClientSet(ctx context.Context, cluster *v1alpha1.EtcdCluster, cli client.Client) (*clientv3.Client, []*clientv3.Client, error)
- func SetCondition(cluster *etcdaenixiov1alpha1.EtcdCluster, condition metav1.Condition)
- type Condition
- type LabelsBuilder
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateOrUpdateClientService ¶
func CreateOrUpdateClientService( ctx context.Context, cluster *etcdaenixiov1alpha1.EtcdCluster, rclient client.Client, ) error
func CreateOrUpdateClusterStateConfigMap ¶
func CreateOrUpdateClusterStateConfigMap( ctx context.Context, cluster *etcdaenixiov1alpha1.EtcdCluster, rclient client.Client, ) error
func CreateOrUpdateHeadlessService ¶ added in v0.2.0
func CreateOrUpdateHeadlessService( ctx context.Context, cluster *etcdaenixiov1alpha1.EtcdCluster, rclient client.Client, ) error
func CreateOrUpdatePdb ¶ added in v0.1.0
func CreateOrUpdatePdb( ctx context.Context, cluster *etcdaenixiov1alpha1.EtcdCluster, rclient client.Client, ) error
func CreateOrUpdateStatefulSet ¶
func CreateOrUpdateStatefulSet( ctx context.Context, cluster *etcdaenixiov1alpha1.EtcdCluster, rclient client.Client, ) error
func FillConditions ¶
func FillConditions(cluster *etcdaenixiov1alpha1.EtcdCluster)
FillConditions fills EtcdCluster .status.Conditions list with all available conditions in "False" status.
func GetClusterStateConfigMapName ¶
func GetClusterStateConfigMapName(cluster *etcdaenixiov1alpha1.EtcdCluster) string
func GetCondition ¶
func GetCondition(cluster *etcdaenixiov1alpha1.EtcdCluster, condType string) *metav1.Condition
GetCondition returns condition from cluster status conditions by type or nil if not present.
func GetHeadlessServiceName ¶ added in v0.2.0
func GetHeadlessServiceName(cluster *etcdaenixiov1alpha1.EtcdCluster) string
func GetPVCName ¶
func GetPVCName(cluster *etcdaenixiov1alpha1.EtcdCluster) string
func GetServerProtocol ¶ added in v0.3.0
func GetServerProtocol(cluster *etcdaenixiov1alpha1.EtcdCluster) string
func GetServiceName ¶ added in v0.2.0
func GetServiceName(cluster *etcdaenixiov1alpha1.EtcdCluster) string
func NewEtcdClientSet ¶ added in v0.3.0
func SetCondition ¶
func SetCondition( cluster *etcdaenixiov1alpha1.EtcdCluster, condition metav1.Condition, )
SetCondition sets either replaces corresponding existing condition in the .status.Conditions list or appends one passed as an argument. In case operation will not result into condition status change, return.
Types ¶
type Condition ¶
Condition is a wrapper over metav1.Condition type.
func NewCondition ¶
func NewCondition(conditionType etcdaenixiov1alpha1.EtcdCondType) Condition
NewCondition returns Condition object with provided condition type.
func (Condition) Complete ¶
Complete finalizes condition building by setting transition timestamp and returns wrapped metav1.Condition object.
func (Condition) WithMessage ¶
WithMessage sets condition message.
func (Condition) WithReason ¶
WithReason sets condition reason.
func (Condition) WithStatus ¶
WithStatus converts boolean value passed as an argument to metav1.ConditionStatus type and sets condition status.
type LabelsBuilder ¶
func NewLabelsBuilder ¶
func NewLabelsBuilder() LabelsBuilder
func (LabelsBuilder) WithInstance ¶
func (b LabelsBuilder) WithInstance(name string) LabelsBuilder
func (LabelsBuilder) WithManagedBy ¶
func (b LabelsBuilder) WithManagedBy() LabelsBuilder
func (LabelsBuilder) WithName ¶
func (b LabelsBuilder) WithName() LabelsBuilder