Class NonRetryableException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- software.amazon.awssdk.core.exception.SdkException
-
- software.amazon.awssdk.core.exception.SdkClientException
-
- software.amazon.awssdk.core.exception.NonRetryableException
-
- All Implemented Interfaces:
Serializable
public final class NonRetryableException extends SdkClientException
Extension ofSdkExceptionthat can be used by clients to explicitly have an exception not retried. This exception will never be thrown by the SDK unless explicitly used by the client. SeeRetryableExceptionfor marking retryable exceptions.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceNonRetryableException.Builderprotected static classNonRetryableException.BuilderImpl
-
Constructor Summary
Constructors Modifier Constructor Description protectedNonRetryableException(NonRetryableException.Builder b)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static NonRetryableException.Builderbuilder()static NonRetryableExceptioncreate(String message)static NonRetryableExceptioncreate(String message, Throwable cause)booleanretryable()Specifies whether or not an exception can be expected to succeed on a retry.NonRetryableException.BuildertoBuilder()Create aSdkClientException.Builderinitialized with the properties of thisSdkClientException.-
Methods inherited from class software.amazon.awssdk.core.exception.SdkClientException
getMessage
-
Methods inherited from class software.amazon.awssdk.core.exception.SdkException
numAttempts, rawMessage
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
NonRetryableException
protected NonRetryableException(NonRetryableException.Builder b)
-
-
Method Detail
-
retryable
public boolean retryable()
Description copied from class:SdkExceptionSpecifies whether or not an exception can be expected to succeed on a retry.- Overrides:
retryablein classSdkException
-
toBuilder
public NonRetryableException.Builder toBuilder()
Description copied from class:SdkClientExceptionCreate aSdkClientException.Builderinitialized with the properties of thisSdkClientException.- Overrides:
toBuilderin classSdkClientException- Returns:
- A new builder initialized with this config's properties.
-
builder
public static NonRetryableException.Builder builder()
-
create
public static NonRetryableException create(String message)
-
create
public static NonRetryableException create(String message, Throwable cause)
-
-