Skip to content

The RestTemplateCustomizer forcibly includes all implementations of ClientHttpRequestInterceptor, which may not be necessary for the restTemplate execution in certain scenarios #1476

Description

@chengyouling

Describe the bug
WebConfiguration包中的设置RestTemplateCustomizer时,会将ClientHttpRequestInterceptor的所有实现类都添加到RestTemplate执行,但是某些情况下,客户只是自己手动拦截处理下逻辑,不需要放到restTemplate中执行,导致与业务逻辑不一致或者异常。

To Reproduce
Sample code:

Expected behavior
A clear and concise description of what you expected to happen.

Information

Spring Cloud Huawei version:
Spring Cloud version(optional):
Spring Boot version(optional):
Spring version(optional):

Additional context
Add any other context about the problem here.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions