This commit is contained in:
k00kzaAntonovaIra
2026-11-16 14:16:01 +03:00
parent 276dbdad8a
commit 8bedaa7592
177 changed files with 17065 additions and 430 deletions
+23
View File
@@ -0,0 +1,23 @@
from fastapi import APIRouter, Request
from app.domain import health
from app.schemas.base import Health
router = APIRouter(prefix="/health", tags=["health"])
@router.get("/live")
async def liveness() -> Health:
return health.liveness()
@router.get("/ready")
async def readiness(request: Request) -> Health:
state = request.app.state
return await health.readiness(
state.engine,
state.redis,
state.s3,
state.lifecycle,
state.settings.readiness_timeout_seconds,
)