test: add SLO incident verification

This commit is contained in:
2026-11-01 17:06:37 +03:00
parent 4bf383bd51
commit 441b752257
16 changed files with 1216 additions and 17 deletions
+59
View File
@@ -0,0 +1,59 @@
{
"schema_version": 1,
"captured_at": "2026-11-01T14:05:43Z",
"baseline": {
"api_request_rate_per_second": 1.1485206460733426,
"firing_alerts": 0,
"traces_by_service": {
"messenger-api": 39,
"messenger-worker": 23,
"messenger-dispatcher": 22
},
"logs_by_service": {
"messenger-api": 162,
"messenger-worker": 40,
"messenger-dispatcher": 1
},
"api_worker_shared_traces": 3,
"traces_with_correlated_logs": 37
},
"incidents": [
{
"name": "worker_unavailable_short",
"injected_duration_seconds": 76,
"alert_detection_upper_bound_seconds": 76,
"alert_resolution_seconds": 15,
"recovery_observation_seconds": 36
},
{
"name": "postgres_unavailable",
"injected_duration_seconds": 76,
"alert_detection_upper_bound_seconds": 76,
"operational_alert_resolution_seconds": 127,
"recovery_observation_seconds": 148,
"fast_burn_alert_observed": true,
"database_error_traces": 4,
"database_error_traces_with_logs": 4
},
{
"name": "worker_unavailable_long",
"injected_duration_seconds": 180,
"alert_detection_upper_bound_seconds": 180,
"alert_resolution_seconds": 15,
"recovery_observation_seconds": 65,
"fast_burn_alert_observed": true,
"slow_burn_alert_observed": true
},
{
"name": "telemetry_backends_unavailable",
"injected_duration_seconds": 30,
"api_ready_http_status": 200,
"recovery_observation_seconds": 31
}
],
"validation": {
"valid": true,
"errors": [],
"incident_summaries": 4
}
}
+37
View File
@@ -0,0 +1,37 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://gitea.privcloud.tech/mtusi2026/mtusi2026lab6/evidence/lab6-schema.json",
"title": "Lab 6 incident summary",
"type": "object",
"required": [
"schema_version",
"incident",
"started_at",
"recovery_started_at",
"recovered_at",
"injected_duration_seconds",
"recovery_observation_seconds",
"artifacts"
],
"properties": {
"schema_version": {"const": 1},
"incident": {
"enum": ["worker_unavailable", "postgres_unavailable", "telemetry_backends_unavailable"]
},
"profile": {"enum": ["short", "long"]},
"started_at": {"type": "string", "format": "date-time"},
"recovery_started_at": {"type": "string", "format": "date-time"},
"recovered_at": {"type": "string", "format": "date-time"},
"planned_injection_seconds": {"type": "integer", "minimum": 1},
"injected_duration_seconds": {"type": "integer", "minimum": 1},
"recovery_observation_seconds": {"type": "integer", "minimum": 0},
"api_ready_http_status_during_outage": {"type": "integer", "minimum": 100, "maximum": 599},
"artifacts": {
"type": "array",
"items": {"type": "string", "pattern": "^[A-Za-z0-9._-]+$"},
"minItems": 4,
"uniqueItems": true
}
},
"additionalProperties": false
}