Skip to content

Commit 22e9407

Browse files
committed
make fmt
1 parent f0660a1 commit 22e9407

File tree

1 file changed

+24
-24
lines changed

1 file changed

+24
-24
lines changed

windows-observ-lib/alerts.libsonnet

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -128,10 +128,10 @@
128128
Total memory: {{ with printf `%(memoryTotal)s` | query | first | value | humanize }}{{ . }}{{ end }}.
129129
Consider investigating processes consuming high memory or increasing available memory.
130130
||| % {
131-
instanceLabel: instanceLabel,
132-
threshold: config.alertMemoryUsageThresholdCritical,
133-
memoryFree: signals.memory.memoryFree.asRuleExpression(),
134-
memoryTotal: signals.memory.memoryTotal.asRuleExpression(),
131+
instanceLabel: instanceLabel,
132+
threshold: config.alertMemoryUsageThresholdCritical,
133+
memoryFree: signals.memory.memoryFree.asRuleExpression(),
134+
memoryTotal: signals.memory.memoryTotal.asRuleExpression(),
135135
},
136136
},
137137
},
@@ -228,26 +228,26 @@
228228
},
229229
},
230230
]
231-
+ if std.member(config.metricsSource, 'prometheus_pre_0_30') then
232-
[
233-
{
234-
alert: 'WindowsServiceNotHealthy',
235-
expr: |||
236-
(%s) > 0
237-
||| % [
238-
signals.services.serviceNotHealthy.asRuleExpression(),
239-
],
240-
'for': '5m',
241-
labels: {
242-
severity: 'critical',
243-
},
244-
annotations: {
245-
summary: 'Windows service is not healthy.',
246-
description: "Windows service {{ $labels.name }} is not in healthy state, currently in '{{ $labels.status }}'.",
247-
},
248-
}
249-
] else []
250-
+ if config.enableADDashboard then ADAlerts else [],
231+
+ if std.member(config.metricsSource, 'prometheus_pre_0_30') then
232+
[
233+
{
234+
alert: 'WindowsServiceNotHealthy',
235+
expr: |||
236+
(%s) > 0
237+
||| % [
238+
signals.services.serviceNotHealthy.asRuleExpression(),
239+
],
240+
'for': '5m',
241+
labels: {
242+
severity: 'critical',
243+
},
244+
annotations: {
245+
summary: 'Windows service is not healthy.',
246+
description: "Windows service {{ $labels.name }} is not in healthy state, currently in '{{ $labels.status }}'.",
247+
},
248+
},
249+
] else []
250+
+ if config.enableADDashboard then ADAlerts else [],
251251
},
252252
],
253253
},

0 commit comments

Comments
 (0)