forked from mtusi2026/mtusi2026lab6
исправления dashboard
This commit is contained in:
+7
-1
@@ -75,6 +75,8 @@ class OtelASGIMiddleware:
|
||||
await self.app(scope, receive, send_wrapper)
|
||||
finally:
|
||||
dur_ms = (time.perf_counter() - started) * 1000.0
|
||||
if status_holder["code"] == 0:
|
||||
status_holder["code"] = 500
|
||||
attrs = {
|
||||
"http.method": method,
|
||||
"http.target": path,
|
||||
@@ -133,4 +135,8 @@ async def health_live():
|
||||
|
||||
@app.get("/health/ready")
|
||||
async def health_ready():
|
||||
return {"status": "ok"}
|
||||
return {"status": "ok"}
|
||||
|
||||
@app.get("/debug/boom")
|
||||
async def debug_boom():
|
||||
raise RuntimeError("demo failure for 5xx alerting")
|
||||
|
||||
Reference in New Issue
Block a user