Update prometheus metrics settings

This commit is contained in:
2023-01-12 12:53:06 +01:00
parent 35e85f1f3c
commit 525e33cdd6

View File

@@ -32,6 +32,9 @@ def start_app() -> FastAPI:
if database_.is_connected: if database_.is_connected:
await database_.disconnect() await database_.disconnect()
Instrumentator().instrument(app).expose(app, include_in_schema=True) Instrumentator(
should_ignore_untemplated=True,
excluded_handlers=["/docs", "/metrics", "/healthcheck"],
).instrument(app).expose(app, include_in_schema=True)
return app return app