Package com.guinetik.rr.auth
Class TokenExpiredException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- com.guinetik.rr.http.RocketRestException
-
- com.guinetik.rr.auth.TokenExpiredException
-
- All Implemented Interfaces:
Serializable
public class TokenExpiredException extends RocketRestException
Exception thrown when an API request fails due to token expiration.This exception is thrown when a request receives a 401 Unauthorized response, indicating that the authentication token has expired or is invalid. The retry mechanism in
AbstractApiClientcatches this exception and attempts to refresh the token before retrying.Exception Hierarchy
RuntimeException └── RocketRestException └── TokenExpiredException- Since:
- 1.0.0
- Author:
- guinetik <guinetik@gmail.com>
- See Also:
RocketRestException,AuthStrategy, Serialized Form
-
-
Constructor Summary
Constructors Constructor Description TokenExpiredException(String message)Creates a new TokenExpiredException with the specified message.TokenExpiredException(String message, Throwable cause)Creates a new TokenExpiredException with the specified message and cause.
-
Method Summary
-
Methods inherited from class com.guinetik.rr.http.RocketRestException
getResponseBody, getStatusCode
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
TokenExpiredException
public TokenExpiredException(String message)
Creates a new TokenExpiredException with the specified message.- Parameters:
message- The exception message
-
-