I have a service that responses HTTP Status Code 302 Found
. When calling it with RequestBuilder.send()
I get redirected automatically, so that the final URL is not equal to the URL initially set for the RequestBuilder.
I need at least the URL the service wants to forward me, in other words the Location
header of the first response.
Is it possible to prevent the request from being forwarded? Or can I examine the URL with the final Response?