Class NettyHttpRedirectController
java.lang.Object
org.glassfish.jersey.netty.connector.NettyHttpRedirectController
The HTTP Redirect logic implementation for Netty Connector.
- Since:
- 2.47
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanprepareRedirect(ClientRequest request, ClientResponse response) Configure the HTTP request after HTTP Redirect response has been received.protected voidrestrictRequestHeaders(ClientRequest request, ClientResponse response) RFC 9110 Section 15.4 defines the HTTP headers that should be removed from the redirected request.
-
Constructor Details
-
NettyHttpRedirectController
public NettyHttpRedirectController()
-
-
Method Details
-
prepareRedirect
Configure the HTTP request after HTTP Redirect response has been received. By default, the HTTP POST request is transformed into HTTP GET for status 301 & 302. Also, HTTP Headers described by RFC 9110 Section 15.4 are removed from the new HTTP Request.- Parameters:
request- The newClientRequestto be sent to the redirected URI.response- The original HTTP redirectClientResponsereceived.- Returns:
truewhen the new request should be sent.
-
restrictRequestHeaders
RFC 9110 Section 15.4 defines the HTTP headers that should be removed from the redirected request. https://httpwg.org/specs/rfc9110.html#rfc.section.15.4.- Parameters:
request- the new request to a new URI location.response- the HTTP redirect response.
-