Package org.glassfish.tyrus.client
Class RedirectException
java.lang.Object
java.lang.Throwable
java.lang.Exception
org.glassfish.tyrus.core.HandshakeException
org.glassfish.tyrus.client.RedirectException
- All Implemented Interfaces:
Serializable
This exception is set as a cause of
DeploymentException
thrown from WebSocketContainer
.connectToServer(...)
when any of the Redirect HTTP response status codes (300, 301, 302, 303, 307, 308) is received as a handshake
response and:
-
ClientProperties.REDIRECT_ENABLED
is not enabled -
or the chained redirection count exceeds the value of
ClientProperties.REDIRECT_THRESHOLD
- or Infinite redirection loop is detected
-
or "Location" response header is missing, empty or does not contain a valid
URI
.
- Author:
- Ondrej Kosatka
- See Also:
-
Constructor Summary
-
Method Summary
Methods inherited from class org.glassfish.tyrus.core.HandshakeException
getHttpStatusCode
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
RedirectException
Constructor.- Parameters:
httpStatusCode
- http status code to be set to response.message
- the detail message. The detail message is saved for later retrieval by theThrowable.getMessage()
method.
-