The problem is we use spring-security-oauth2-client 5.3.4 in order to get the authorization token from the external autorization server and each first request (when there is no token in memory) there is an error comes with
SocketException thrown: Broken pipe (Write failed).
But on the second request everything is ok and token comes from server.
oauth2-client uses almost default restemplate inside and I have no idea why first request is failure, if someone can help I would be very grateful, thanks in advance
We tried to change the client on okhttp but no difference