I have a spring boot client application that uses RestTemplate to talk to a few end points. Right now the resttemplate has the same connect timeout for each end point.
There is a new requirement to configure different timeouts based on the end point. I am using RestTemplateBuilder to configure the Rest Template during application start up. After reading through other posts I figured there are couple of ways to achieve this.
First option is to configure a rest template for each end point(want to stay away from this as there could be lot of end points in future) and the second option is to have the ability to set connect timeouts for every request .
I specifically want to check if there is a way to set timeouts per request using the same rest template.