My development environment is behind the proxy server, so I need to set the proxy information to the rest of the template, which is good when I use the HttpComponentsClientHttpRequestFactory and set the proxy parameter to httpClient and set it in the template.
But now I have a recreation service that requires basic auth. And in order to set the basic credentials, I need to set them in httpClient in the break pattern. But I see that the getparams method in httpClient is deprived, so I canβt just update the existing client in the template, and if I create a new httpclient object, I will overwrite the proxy information that was installed during the initial loading of the application.
So is there a way I could extract the httpClient from the rest of the template and update it? Or is there any other way to handle this?
Thank.
source
share