forked from mtusi2026/mtusi2026lab6
Implement Lab 6 observability
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"lab": 6,
|
||||
"workload": "closed-loop POST messages; no automatic retries",
|
||||
"requested_duration_seconds": 8.0,
|
||||
"elapsed_seconds": 8.016,
|
||||
"concurrency": 2,
|
||||
"successful_requests": 1500,
|
||||
"failed_requests": 0,
|
||||
"error_ratio": 0.0,
|
||||
"successful_rps": 187.126,
|
||||
"successful_latency_ms": {
|
||||
"p50": 15.0,
|
||||
"p95": 31.0,
|
||||
"p99": 32.0
|
||||
},
|
||||
"note": "Latency percentiles cover successes only. Timeouts/errors are counted separately; closed-loop has coordinated omission and client overhead."
|
||||
}
|
||||
@@ -0,0 +1,124 @@
|
||||
{
|
||||
"dashboard": "lab-messenger",
|
||||
"metrics": {
|
||||
"sum(messenger_http_requests_total)": 2445.0,
|
||||
"sum(messenger_http_requests_total{http_status_class=\"5xx\"})": 5.0,
|
||||
"sum(messenger_http_duration_seconds_count)": 2445.0,
|
||||
"sum(messenger_job_deliveries_total{job_outcome=\"ready\"})": 3.0,
|
||||
"sum(messenger_job_deliveries_total{job_outcome=\"failed\"})": 1.0,
|
||||
"sum(messenger_job_duration_seconds_count)": 8.0
|
||||
},
|
||||
"api_correlation": {
|
||||
"log": {
|
||||
"event": "http.request",
|
||||
"service": "messenger-api",
|
||||
"request_id": "5fab7c41-45c0-4858-9083-916a356be9a7",
|
||||
"method": "POST",
|
||||
"route": "/api/v1/chats/{chat_id}/messages",
|
||||
"status": 201,
|
||||
"duration_ms": 7.05,
|
||||
"trace_id": "b87ae9bb16beea84ef60bc1dc1f447cc",
|
||||
"span_id": "a531d01e14510c6e"
|
||||
},
|
||||
"trace": {
|
||||
"name": "POST /api/v1/chats/{chat_id}/messages",
|
||||
"kind": "SPAN_KIND_SERVER",
|
||||
"attributes": {
|
||||
"http.request.method": "POST",
|
||||
"http.route": "/api/v1/chats/{chat_id}/messages",
|
||||
"http.response.status_code": "201",
|
||||
"request.id": "5fab7c41-45c0-4858-9083-916a356be9a7"
|
||||
},
|
||||
"events": []
|
||||
}
|
||||
},
|
||||
"worker_correlation": {
|
||||
"log": {
|
||||
"event": "job.process",
|
||||
"service": "messenger-worker",
|
||||
"job_type": "attachment.process.v1",
|
||||
"job_id": "c88bc1dd-4db2-4847-b130-f84b699078b0",
|
||||
"attachment_id": "9006033d-d6a1-498d-a3f3-ff840a3ab169",
|
||||
"attempt": 1,
|
||||
"outcome": "ready",
|
||||
"reason": "completed",
|
||||
"duration_ms": 19.389,
|
||||
"trace_id": "14cfaf613183dcc9449ea94dcf359a6f",
|
||||
"span_id": "c06c5be6126e576b"
|
||||
},
|
||||
"trace": {
|
||||
"name": "attachment.process.v1 process",
|
||||
"kind": "SPAN_KIND_CONSUMER",
|
||||
"attributes": {
|
||||
"messaging.system": "rabbitmq",
|
||||
"messaging.destination.name": "attachment.process.v1",
|
||||
"messaging.operation.type": "process",
|
||||
"messaging.message.id": "c88bc1dd-4db2-4847-b130-f84b699078b0",
|
||||
"attachment.id": "9006033d-d6a1-498d-a3f3-ff840a3ab169",
|
||||
"job.attempt": "1",
|
||||
"job.outcome": "ready",
|
||||
"job.reason": "completed"
|
||||
},
|
||||
"events": []
|
||||
}
|
||||
},
|
||||
"postgresql_incident": {
|
||||
"log": {
|
||||
"event": "http.request",
|
||||
"service": "messenger-api",
|
||||
"request_id": "0084b9e7-97d9-47ae-8394-36e8b70c74f1",
|
||||
"method": "GET",
|
||||
"route": "/health/ready",
|
||||
"status": 503,
|
||||
"duration_ms": 3001.269,
|
||||
"trace_id": "f73f9e68c796d4868325485e2e94177d",
|
||||
"span_id": "f98e20c6167c2e72"
|
||||
},
|
||||
"trace": {
|
||||
"name": "GET /health/ready",
|
||||
"kind": "SPAN_KIND_SERVER",
|
||||
"attributes": {
|
||||
"http.request.method": "GET",
|
||||
"http.route": "/health/ready",
|
||||
"http.response.status_code": "503",
|
||||
"request.id": "0084b9e7-97d9-47ae-8394-36e8b70c74f1"
|
||||
},
|
||||
"events": [
|
||||
"postgresql.unavailable"
|
||||
]
|
||||
}
|
||||
},
|
||||
"staging_incident": {
|
||||
"log": {
|
||||
"event": "job.process",
|
||||
"service": "messenger-worker",
|
||||
"job_type": "attachment.process.v1",
|
||||
"job_id": "4a59e1e7-913b-4197-82d9-7362b8d5fd0f",
|
||||
"attachment_id": "ddb7648f-6101-4499-8f8f-716ef7ab354f",
|
||||
"attempt": 5,
|
||||
"outcome": "failed",
|
||||
"reason": "staging_unavailable",
|
||||
"duration_ms": 6.487,
|
||||
"trace_id": "334430e49f915695042a69f79db598f4",
|
||||
"span_id": "65282ea2a6dd5453"
|
||||
},
|
||||
"trace": {
|
||||
"name": "attachment.process.v1 process",
|
||||
"kind": "SPAN_KIND_CONSUMER",
|
||||
"attributes": {
|
||||
"messaging.system": "rabbitmq",
|
||||
"messaging.destination.name": "attachment.process.v1",
|
||||
"messaging.operation.type": "process",
|
||||
"messaging.message.id": "4a59e1e7-913b-4197-82d9-7362b8d5fd0f",
|
||||
"attachment.id": "ddb7648f-6101-4499-8f8f-716ef7ab354f",
|
||||
"job.attempt": "5",
|
||||
"job.outcome": "failed",
|
||||
"job.reason": "staging_unavailable"
|
||||
},
|
||||
"events": []
|
||||
}
|
||||
},
|
||||
"staging_attempts": 5,
|
||||
"message_status_with_tempo_stopped": 201,
|
||||
"message_marker_absent": true
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
{
|
||||
"attachment_id": "5e40e04f-7c59-474f-98bc-55ccbf8bfae4",
|
||||
"message_id": "7594f573-c2ba-4a65-b894-738dd3c41605",
|
||||
"upload_status": 202,
|
||||
"content_while_queued": 409,
|
||||
"queued_jobs_after_broker_restart_with_dispatcher_stopped": 1,
|
||||
"api_instance_ids_before": [
|
||||
"7465b626dc9e42b08f18e746fbe52754",
|
||||
"8c6d9168efea4625858e7c1e318171b9"
|
||||
],
|
||||
"api_instance_ids_after": [
|
||||
"7b57ff1e300249e8bfe5341ab36ac951",
|
||||
"d8f978d38b124d27862290a2528bd39d"
|
||||
],
|
||||
"message_preserved_after_restart": true,
|
||||
"final_status": "ready",
|
||||
"original_bytes_match": true,
|
||||
"thumbnail": {
|
||||
"name": "thumbnail",
|
||||
"width": 256,
|
||||
"height": 160,
|
||||
"sha256": "b8e59b0cad429b1c49c27c4a1c79e52bfc23e2fab7c7238d18d5addd4df4b546",
|
||||
"size_bytes": 5813,
|
||||
"content_type": "image/jpeg"
|
||||
},
|
||||
"duplicate_acknowledged": true,
|
||||
"duplicate_preserved_metadata_and_bytes": true,
|
||||
"retry_limit": {
|
||||
"attachment_id": "ef2bfe35-cf02-47fb-9ea8-abab14a5f623",
|
||||
"attempts": 5,
|
||||
"status": "failed",
|
||||
"error_code": "retry_exhausted"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user