Skip to content

Commit

Permalink
adding a service check
Browse files Browse the repository at this point in the history
  • Loading branch information
rahulkaukuntla committed Oct 25, 2024
1 parent 12883f9 commit d21f96d
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
18 changes: 17 additions & 1 deletion scaphandre/assets/service_checks.json
Original file line number Diff line number Diff line change
@@ -1 +1,17 @@
[]
[
{
"agent_version": "7.60.0",
"integration": "Scaphandre",
"check": "scaphandre.openmetrics.health",
"statuses": [
"ok",
"critical"
],
"groups": [
"host",
"endpoint"
],
"name": "scaphandre OpenMetrics endpoint health",
"description": "Returns `CRITICAL` if the Agent is unable to connect to the Scaphandre OpenMetrics endpoint, otherwise returns `OK`."
}
]
1 change: 1 addition & 0 deletions scaphandre/tests/test_unit.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ def test_check(dd_run_check, aggregator, mock_http_response):
for metric in METRICS:
aggregator.assert_metric(f'scaphandre.{metric}')

aggregator.assert_service_check('scaphandre.openmetrics.health', ServiceCheck.OK)
aggregator.assert_all_metrics_covered()
aggregator.assert_metrics_using_metadata(get_metadata_metrics())
aggregator.assert_service_check('scaphandre.openmetrics.health', ServiceCheck.OK)

0 comments on commit d21f96d

Please sign in to comment.