language models and set defaults are updated
This commit is contained in:
@@ -65,7 +65,9 @@ def setup_exception_handlers(app: FastAPI) -> None:
|
||||
"""
|
||||
custom_exception_handler = HTTPExceptionApiHandler(response_model=JSONResponse)
|
||||
app.add_exception_handler(ValidationError, validation_exception_handler)
|
||||
app.add_exception_handler(HTTPExceptionApi, custom_exception_handler.handle_exception)
|
||||
app.add_exception_handler(
|
||||
HTTPExceptionApi, custom_exception_handler.handle_exception
|
||||
)
|
||||
app.add_exception_handler(Exception, generic_exception_handler)
|
||||
|
||||
|
||||
|
||||
@@ -16,16 +16,6 @@ from Events.Engine.set_defaults.setClusters import (
|
||||
routers: Optional[PrepareRouting] = None
|
||||
|
||||
|
||||
# async def health_check(request: Request):
|
||||
# """Default health check endpoint."""
|
||||
# return {"status": "healthy", "message": "Service is running"}
|
||||
#
|
||||
#
|
||||
# async def ping_test(request: Request, service_name: str = "base-router"):
|
||||
# """Default ping test endpoint."""
|
||||
# return {"ping": "pong", "service": service_name}
|
||||
|
||||
|
||||
def get_all_routers() -> PrepareRouting:
|
||||
"""
|
||||
Get all routers and protected routes from route configurations.
|
||||
@@ -41,3 +31,13 @@ def get_all_routers() -> PrepareRouting:
|
||||
prepare_events = PrepareEvents(cluster_controller_group=cluster_list)
|
||||
SetItems2Redis(prepare_events=prepare_events)
|
||||
return prepare_routing
|
||||
|
||||
|
||||
# async def health_check(request: Request):
|
||||
# """Default health check endpoint."""
|
||||
# return {"status": "healthy", "message": "Service is running"}
|
||||
#
|
||||
#
|
||||
# async def ping_test(request: Request, service_name: str = "base-router"):
|
||||
# """Default ping test endpoint."""
|
||||
# return {"ping": "pong", "service": service_name}
|
||||
|
||||
Reference in New Issue
Block a user