mirror of
https://github.com/bellingcat/auto-archiver-api.git
synced 2026-06-12 13:38:33 +03:00
minor fixes and todos
This commit is contained in:
@@ -8,6 +8,8 @@ from app.web.utils.metrics import EXCEPTION_COUNTER
|
||||
async def logging_middleware(request: Request, call_next):
|
||||
try:
|
||||
response = await call_next(request)
|
||||
#TODO: use Origin to have summary prometheus metrics on where requests come from
|
||||
# origin = request.headers.get("origin")
|
||||
logger.info(f"{request.client.host}:{request.client.port} {request.method} {request.url._url} - HTTP {response.status_code}")
|
||||
return response
|
||||
except Exception as e:
|
||||
|
||||
Reference in New Issue
Block a user