fix a typo about events
Signed-off-by: Poor12 <shentiecheng@huawei.com>
This commit is contained in:
parent
2a53cf8a4f
commit
047b2fb7ae
|
@ -6,8 +6,8 @@ const (
|
|||
EventReasonCreateExecutionSpaceFailed = "CreateExecutionSpaceFailed"
|
||||
// EventReasonRemoveExecutionSpaceFailed indicates that remove execution space failed.
|
||||
EventReasonRemoveExecutionSpaceFailed = "RemoveExecutionSpaceFailed"
|
||||
// EventReasonTaintClusterByConditionFailed indicates that taint cluster by condition
|
||||
EventReasonTaintClusterByConditionFailed = "TaintClusterByCondition"
|
||||
// EventReasonTaintClusterByConditionFailed indicates that taint cluster by condition failed.
|
||||
EventReasonTaintClusterByConditionFailed = "TaintClusterByConditionFailed"
|
||||
// EventReasonRemoveTargetClusterFailed indicates that failed to remove target cluster from binding.
|
||||
EventReasonRemoveTargetClusterFailed = "RemoveTargetClusterFailed"
|
||||
)
|
||||
|
|
|
@ -215,14 +215,14 @@ func (c *Controller) syncCluster(ctx context.Context, cluster *clusterv1alpha1.C
|
|||
// create execution space
|
||||
err := c.createExecutionSpace(cluster)
|
||||
if err != nil {
|
||||
c.EventRecorder.Event(cluster, corev1.EventTypeWarning, fmt.Sprintf("Failed %s", clusterv1alpha1.EventReasonCreateExecutionSpaceFailed), err.Error())
|
||||
c.EventRecorder.Event(cluster, corev1.EventTypeWarning, clusterv1alpha1.EventReasonCreateExecutionSpaceFailed, err.Error())
|
||||
return controllerruntime.Result{Requeue: true}, err
|
||||
}
|
||||
|
||||
// taint cluster by condition
|
||||
err = c.taintClusterByCondition(ctx, cluster)
|
||||
if err != nil {
|
||||
c.EventRecorder.Event(cluster, corev1.EventTypeWarning, fmt.Sprintf("Failed %s", clusterv1alpha1.EventReasonTaintClusterByConditionFailed), err.Error())
|
||||
c.EventRecorder.Event(cluster, corev1.EventTypeWarning, clusterv1alpha1.EventReasonTaintClusterByConditionFailed, err.Error())
|
||||
return controllerruntime.Result{Requeue: true}, err
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue