| 程序包 | 说明 |
|---|---|
| com.github.lianjiatech.retrofit.spring.boot.config | |
| com.github.lianjiatech.retrofit.spring.boot.retry |
| 限定符和类型 | 字段和说明 |
|---|---|
private RetryRule[] |
RetryProperty.globalRetryRules
重试规则,默认 响应状态码不是2xx 或者 发生IO异常 时触发重试
Retry rule
|
| 限定符和类型 | 方法和说明 |
|---|---|
RetryRule[] |
RetryProperty.getGlobalRetryRules() |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
RetryProperty.setGlobalRetryRules(RetryRule[] globalRetryRules) |
| 限定符和类型 | 字段和说明 |
|---|---|
private RetryRule[] |
BaseRetryInterceptor.globalRetryRules |
| 限定符和类型 | 方法和说明 |
|---|---|
static RetryRule |
RetryRule.valueOf(String name)
返回带有指定名称的该类型的枚举常量。
|
static RetryRule[] |
RetryRule.values()
按照声明该枚举类型的常量的顺序, 返回
包含这些常量的数组。
|
| 限定符和类型 | 方法和说明 |
|---|---|
protected okhttp3.Response |
DefaultRetryInterceptor.retryIntercept(int maxRetries,
int intervalMs,
RetryRule[] retryRules,
okhttp3.Interceptor.Chain chain) |
protected abstract okhttp3.Response |
BaseRetryInterceptor.retryIntercept(int maxRetries,
int intervalMs,
RetryRule[] retryRules,
okhttp3.Interceptor.Chain chain)
process a retryable request
The access level here is set to protected, which can facilitate business personalized expansion
这里访问级别设置为protected,可方便业务个性化扩展
|
void |
BaseRetryInterceptor.setGlobalRetryRules(RetryRule[] globalRetryRules) |
| 限定符和类型 | 方法和说明 |
|---|---|
private boolean |
DefaultRetryInterceptor.shouldThrowEx(HashSet<RetryRule> retryRuleSet,
Exception e) |
Copyright © 2022. All rights reserved.