Skip to content

Commit 8ee8a6e

Browse files
authored
Add defaults for days_critical and days_warning config options (#20062)
* Add defaults for days_critical and days_warning config options * Add changelog
1 parent 1522d8a commit 8ee8a6e

File tree

4 files changed

+15
-4
lines changed

4 files changed

+15
-4
lines changed

http_check/assets/configuration/spec.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,10 +139,12 @@ files:
139139
description: Express warning threshold for the HTTP check in days
140140
value:
141141
type: integer
142+
example: 14
142143
- name: days_critical
143144
description: Express critical threshold for the HTTP check in days
144145
value:
145146
type: integer
147+
example: 7
146148
- name: seconds_warning
147149
description: |
148150
Alternatively to days_warning, seconds_warning expresses

http_check/changelog.d/20062.added

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Add defaults for `days_critical` and `days_warning` config options

http_check/datadog_checks/http_check/config_models/defaults.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,14 @@ def instance_collect_response_time():
3232
return True
3333

3434

35+
def instance_days_critical():
36+
return 7
37+
38+
39+
def instance_days_warning():
40+
return 14
41+
42+
3543
def instance_disable_generic_tags():
3644
return False
3745

http_check/datadog_checks/http_check/data/conf.yaml.example

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -153,15 +153,15 @@ instances:
153153
#
154154
# tls_retrieve_non_validated_cert: false
155155

156-
## @param days_warning - integer - optional
156+
## @param days_warning - integer - optional - default: 14
157157
## Express warning threshold for the HTTP check in days
158158
#
159-
# days_warning: <DAYS_WARNING>
159+
# days_warning: 14
160160

161-
## @param days_critical - integer - optional
161+
## @param days_critical - integer - optional - default: 7
162162
## Express critical threshold for the HTTP check in days
163163
#
164-
# days_critical: <DAYS_CRITICAL>
164+
# days_critical: 7
165165

166166
## @param seconds_warning - integer - optional
167167
## Alternatively to days_warning, seconds_warning expresses

0 commit comments

Comments
 (0)