HADOOP-14116:FailoverOnNetworkExceptionRetry does not wait when failover
on certain exception. Contributed by Jian He
(cherry picked from commit 289bc50e66
)
This commit is contained in:
parent
bd3c2a2ee9
commit
5c509f5f0c
|
@ -683,7 +683,8 @@ public class RetryPolicies {
|
||||||
} else if (e instanceof SocketException
|
} else if (e instanceof SocketException
|
||||||
|| (e instanceof IOException && !(e instanceof RemoteException))) {
|
|| (e instanceof IOException && !(e instanceof RemoteException))) {
|
||||||
if (isIdempotentOrAtMostOnce) {
|
if (isIdempotentOrAtMostOnce) {
|
||||||
return RetryAction.FAILOVER_AND_RETRY;
|
return new RetryAction(RetryAction.RetryDecision.FAILOVER_AND_RETRY,
|
||||||
|
getFailoverOrRetrySleepTime(retries));
|
||||||
} else {
|
} else {
|
||||||
return new RetryAction(RetryAction.RetryDecision.FAIL, 0,
|
return new RetryAction(RetryAction.RetryDecision.FAIL, 0,
|
||||||
"the invoked method is not idempotent, and unable to determine "
|
"the invoked method is not idempotent, and unable to determine "
|
||||||
|
|
Loading…
Reference in New Issue