Skip to content

Commit

Permalink
OCM-8587 | fix: colon not present in some field for describing autosc…
Browse files Browse the repository at this point in the history
…aler to a cluster
  • Loading branch information
aaraj7 committed Jun 6, 2024
1 parent fdfe4a5 commit f739bf2
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions pkg/clusterautoscaler/output.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ func PrintAutoscaler(a *cmv1.ClusterAutoscaler) string {
out := "\n"
out += fmt.Sprintf("Balance Similar Node Groups: %s\n",
output.PrintBool(a.BalanceSimilarNodeGroups()))
out += fmt.Sprintf("Skip Nodes With Local Storage %s\n",
out += fmt.Sprintf("Skip Nodes With Local Storage: %s\n",
output.PrintBool(a.SkipNodesWithLocalStorage()))
out += fmt.Sprintf("Log Verbosity: %d\n",
a.LogVerbosity())
Expand Down Expand Up @@ -60,7 +60,7 @@ func PrintAutoscaler(a *cmv1.ClusterAutoscaler) string {

//Scale Down
out += "Scale Down:\n"
out += fmt.Sprintf(" - Enabled %s\n",
out += fmt.Sprintf(" - Enabled: %s\n",
output.PrintBool(a.ScaleDown().Enabled()))

if a.ScaleDown().UnneededTime() != "" {
Expand Down
8 changes: 4 additions & 4 deletions pkg/clusterautoscaler/output_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (

var optionalFieldOutput = `
Balance Similar Node Groups: No
Skip Nodes With Local Storage Yes
Skip Nodes With Local Storage: Yes
Log Verbosity: 2
Labels Ignored For Node Balancing: foo, bar
Ignore DaemonSets Utilization: Yes
Expand All @@ -30,7 +30,7 @@ Resource Limits:
- Min: 10
- Max: 20
Scale Down:
- Enabled Yes
- Enabled: Yes
- Node Unneeded Time: 25m
- Node Utilization Threshold: 20
- Delay After Node Added: 5m
Expand All @@ -40,7 +40,7 @@ Scale Down:

var mandatoryFieldOutput = `
Balance Similar Node Groups: No
Skip Nodes With Local Storage Yes
Skip Nodes With Local Storage: Yes
Log Verbosity: 2
Ignore DaemonSets Utilization: Yes
Maximum Pod Grace Period: 10
Expand All @@ -52,7 +52,7 @@ Resource Limits:
- Minimum Memory (GiB): 5
- Maximum Memory (GiB): 10
Scale Down:
- Enabled Yes
- Enabled: Yes
- Node Utilization Threshold: 20
`

Expand Down

0 comments on commit f739bf2

Please sign in to comment.