HttpComponentsClientHttpConnector should close underlying resources #27032
Labels
in: web
Issues in web modules (web, webmvc, webflux, websocket)
type: enhancement
A general enhancement
Milestone
As seen in spring-projects/spring-boot#26214 (comment), the
HttpComponentsClientHttpConnector
can be instantiated with a custom client instance or create a default one. The connector implementation doesn't provide access to the underlying client nor implements theCloseable
interface.We should ensure that the connector can close the resources it's using. This should not be done through the
WebClient
interface since client resources can be shared amongst clients or even with the server.In the case of the
HttpComponentsClientHttpConnector
in Spring Boot, it is created as a Spring bean and will be considered when components are shut down.The text was updated successfully, but these errors were encountered: