fix: exclude infrastructure probes from API throttling
All checks were successful
Mostovik Backend CI/CD / Tests and lint (push) Successful in 3m28s
Mostovik Backend CI/CD / Build linux/amd64 release images (push) Successful in 3m23s
Mostovik Backend CI/CD / Deploy and verify internal main (push) Has been skipped
Mostovik Backend CI/CD / Deploy dev (push) Successful in 1m49s

This commit is contained in:
Aleksandr Meshchryakov
2026-09-16 09:39:56 +02:00
parent 2cfc057e34
commit 4c869b856c
7 changed files with 157 additions and 104 deletions

View File

@@ -167,6 +167,7 @@ class LivenessView(APIView):
permission_classes = [AllowAny]
authentication_classes = []
throttle_classes = []
@swagger_auto_schema(
tags=[HEALTH_TAG],
@@ -174,7 +175,7 @@ class LivenessView(APIView):
operation_description="Возвращает 200 если приложение запущено.",
responses={
200: "Приложение запущено",
**ErrorResponses.PUBLIC,
500: CommonResponses.SERVER_ERROR,
},
)
def get(self, request: Request) -> Response:
@@ -202,7 +203,7 @@ class ReadinessView(APIView):
responses={
200: "Приложение готово обрабатывать запросы",
503: CommonResponses.SERVICE_UNAVAILABLE,
**ErrorResponses.PUBLIC,
500: CommonResponses.SERVER_ERROR,
},
)
def get(self, request: Request) -> Response:

View File

@@ -10818,22 +10818,6 @@
"200": {
"description": "Приложение запущено"
},
"429": {
"description": "Превышен лимит запросов",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"detail": {
"type": "string",
"default": "Превышен лимит запросов. Повторите позже."
}
}
}
}
}
},
"500": {
"description": "Внутренняя ошибка сервера",
"content": {
@@ -10882,22 +10866,6 @@
"200": {
"description": "Приложение готово обрабатывать запросы"
},
"429": {
"description": "Превышен лимит запросов",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"detail": {
"type": "string",
"default": "Превышен лимит запросов. Повторите позже."
}
}
}
}
}
},
"500": {
"description": "Внутренняя ошибка сервера",
"content": {