REFACTOR API gateway fix 5

This commit is contained in:
Urtzi Alfaro
2025-07-26 21:10:54 +02:00
parent dacf114922
commit 7d5c8bc9a4
6 changed files with 91 additions and 19 deletions

View File

@@ -67,10 +67,21 @@ async def startup_event():
logger.info("Starting API Gateway")
# Start metrics server
metrics_collector.start_metrics_server(8080)
metrics_collector.register_counter(
"gateway_auth_requests_total",
"Total authentication requests through gateway"
)
metrics_collector.register_counter(
"gateway_auth_responses_total",
"Total authentication responses through gateway"
)
metrics_collector.register_histogram(
"gateway_request_duration_seconds",
"Gateway request duration"
)
# Initialize service discovery
# await service_discovery.initialize()
metrics_collector.start_metrics_server(8080)
logger.info("API Gateway started successfully")