Yandex Cloud
Поиск
Связаться с намиПодключиться
  • Истории успеха
  • Документация
  • Блог
  • Все сервисы
  • Статус работы сервисов
    • Доступны в регионе
    • Инфраструктура и сеть
    • Платформа данных
    • Контейнеры
    • Инструменты разработчика
    • Бессерверные вычисления
    • Безопасность
    • Мониторинг и управление ресурсами
    • AI Studio
    • Бизнес-инструменты
  • Все решения
    • По отраслям
    • По типу задач
    • Экономика платформы
    • Безопасность
    • Техническая поддержка
    • Каталог партнёров
    • Обучение и сертификация
    • Облако для стартапов
    • Облако для крупного бизнеса
    • Центр технологий для общества
    • Партнёрская программа
    • Поддержка IT-бизнеса
    • Облако для фрилансеров
    • Обучение и сертификация
    • Блог
    • Документация
    • Мероприятия и вебинары
    • Контакты, чаты и сообщества
    • Идеи
    • Тарифы Yandex Cloud
    • Промоакции и free tier
    • Правила тарификации
  • Истории успеха
  • Документация
  • Блог
Проект Яндекса
© 2025 ТОО «Облачные Сервисы Казахстан»
Yandex AI Studio
  • Совместимость с OpenAI
    • О Yandex Cloud ML SDK
      • Overview
      • Authentication
      • Request retries
  • Управление доступом
  • Правила тарификации
  • Аудитные логи Audit Trails
  • Публичные материалы
  • История изменений

В этой статье:

  • Retries configuration
  • class yandex_cloud_ml_sdk._retry.RetryPolicy
  • Interceptors impletentation
  • class yandex_cloud_ml_sdk._retry.UnaryUnaryRetryInterceptor
  • class yandex_cloud_ml_sdk._retry.UnaryStreamRetryInterceptor
  1. Yandex Cloud ML SDK
  2. Справочник SDK (англ.)
  3. Request retries

Request retries

Статья создана
Yandex Cloud
Обновлена 25 августа 2025 г.
  • Retries configuration
    • class yandex_cloud_ml_sdk._retry.RetryPolicy
  • Interceptors impletentation
    • class yandex_cloud_ml_sdk._retry.UnaryUnaryRetryInterceptor
    • class yandex_cloud_ml_sdk._retry.UnaryStreamRetryInterceptor

Some general info about how retries works

Retries configurationRetries configuration

class yandexcloudmlsdk.retry.RetryPolicyclass yandex_cloud_ml_sdk._retry.RetryPolicy

A class that defines a retry policy for network operations.

max_attempts: int = 5

the maximum number of retry attempts

initial_backoff: float = 1

the initial backoff time (in seconds)

max_backoff: float = 10

the maximum backoff time (in seconds)

backoff_multiplier: float = 1.5

the multiplier applied to the backoff after each attempt

jitter: float = 1

the maximum amount of jitter to add to the backoff

retriable_codes: Iterable[StatusCode] = (StatusCode.UNAVAILABLE, StatusCode.RESOURCE_EXHAUSTED)

the grpc status codes that are considered retriable

get_interceptors()

Return type

tuple[ClientInterceptor, …]

async sleep(attempt, deadline)

Parameters

  • attempt (int)
  • deadline (float | None)

Return type

None

Interceptors impletentationInterceptors impletentation

class yandexcloudmlsdk.retry.UnaryUnaryRetryInterceptorclass yandex_cloud_ml_sdk._retry.UnaryUnaryRetryInterceptor

class yandexcloudmlsdk.retry.UnaryStreamRetryInterceptorclass yandex_cloud_ml_sdk._retry.UnaryStreamRetryInterceptor

Была ли статья полезна?

Предыдущая
Batch
Следующая
Обзор
Проект Яндекса
© 2025 ТОО «Облачные Сервисы Казахстан»