public class BinaryExceptionClassifierRetryPolicy extends Object implements RetryPolicy
BinaryExceptionClassifier. Usually, binary
classification is enough for retry purposes. If you need more flexible classification,
use ExceptionClassifierRetryPolicy.| Constructor and Description |
|---|
BinaryExceptionClassifierRetryPolicy(BinaryExceptionClassifier exceptionClassifier) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canRetry(RetryContext context) |
void |
close(RetryContext status) |
BinaryExceptionClassifier |
getExceptionClassifier() |
RetryContext |
open(RetryContext parent)
Acquire resources needed for the retry operation.
|
void |
registerThrowable(RetryContext context,
Throwable throwable)
Called once per retry attempt, after the callback fails.
|
public BinaryExceptionClassifierRetryPolicy(BinaryExceptionClassifier exceptionClassifier)
public BinaryExceptionClassifier getExceptionClassifier()
public boolean canRetry(RetryContext context)
canRetry in interface RetryPolicycontext - the current retry statuspublic void close(RetryContext status)
close in interface RetryPolicystatus - a retry status created by the RetryPolicy.open(RetryContext) method of
this policy.public void registerThrowable(RetryContext context, Throwable throwable)
RetryPolicyregisterThrowable in interface RetryPolicycontext - the current status object.throwable - the exception to throwpublic RetryContext open(RetryContext parent)
RetryPolicyopen in interface RetryPolicyparent - the parent context if we are in a nested retry.RetryContext object specific to this policy.Copyright © 2022 SpringSource. All rights reserved.