You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I include object of APIRouter() to app, I don't see metrics from router endpoints.
In the example below there is no /create_abtest metric in /metrics, only endpoints from app
How can I solve it?
When I include object of APIRouter() to app, I don't see metrics from router endpoints.
In the example below there is no /create_abtest metric in /metrics, only endpoints from app
How can I solve it?
front_routes = APIRouter()
@front_routes.post("/create_abtest/")
async def create_abtest():
...
app = FastAPI(
description=description,
version="0.9",
openapi_url=f"/openapi.json",
docs_url=f"/docs",
redoc_url=f"/redoc",
)
app.include_router(
front_routes,
prefix='/api/v1',
tags=['front_views'],
responses={
404: {"description": "Not Found"}
}
)
instrumentator = Instrumentator()
instrumentator.instrument(app).expose(app)
The text was updated successfully, but these errors were encountered: