Skip to content

Commit 06a8f8d

Browse files
authored
On invalid configmap, scheduler ctrl should return (#258)
1 parent 9f3a2d9 commit 06a8f8d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

controllers/scheduler_controller.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,13 +124,15 @@ func (r *SchedulerReconciler) Reconcile(ctx context.Context, req ctrl.Request) (
124124
// Get human readable status from configmap...
125125
readableStatus, ok := cm.Data["status"]
126126
if !ok {
127-
err := fmt.Errorf("Invalid configmap: no status")
127+
err := fmt.Errorf("invalid configmap: no status")
128128
log.Error(
129129
err,
130130
"unable to parse ClusterAutoscaler status",
131131
"namespace", r.Configuration.ClusterAutoscalerNamespace,
132132
"name", r.Configuration.ClusterAutoscalerStatusName,
133133
)
134+
135+
return ctrl.Result{}, err
134136
}
135137

136138
// ... and parse it.

0 commit comments

Comments
 (0)