202205-03 解决RestTemplate 请求接收自定义400+ 或500+错误 目录RestTemplate请求接收自定义400+或500+错误场景原因解决办法自定义RestTemplate的ResponseErrorHandlerSpring框架中的RestTemplate处理ClientHttpResponse的方式并不想让它抛异常无法使用IOC注入的场景下RestTemplate请求接收自定义400+或500+错误场景当服务端自定义400错误返回体时,使用restTemplate请求接收不到消息体。而我正想根据不同的错误信息做不同的操作。原因restTemplate内置了自己的处理异常的方法ResponseEr... 继续阅读 >