RetryConfig

data class RetryConfig(val maxRetries: Int? = null, val exponentialDelay: Boolean = false, val retryOnServerErrors: Boolean = false)(source)

文件配置中的 HTTP 请求重试选项。

仅在 maxRetries 非空时安装 HttpRequestRetry

Since

4.5.0

Constructors

Link copied to clipboard
constructor(maxRetries: Int? = null, exponentialDelay: Boolean = false, retryOnServerErrors: Boolean = false)

Properties

Link copied to clipboard

是否使用 Ktor 默认指数退避。

Link copied to clipboard

最大重试次数;为 null 时不启用重试。

Link copied to clipboard

是否重试服务器错误响应。