Package org.apache.hadoop.io.retry
Class RetryInvocationHandler<T>
java.lang.Object
org.apache.hadoop.io.retry.RetryInvocationHandler<T>
- All Implemented Interfaces:
Closeable,AutoCloseable,InvocationHandler,RpcInvocationHandler
- Direct Known Subclasses:
LossyRetryInvocationHandler
A
RpcInvocationHandler which supports client side retry .-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedRetryInvocationHandler(FailoverProxyProvider<T> proxyProvider, RetryPolicy retryPolicy) protectedRetryInvocationHandler(FailoverProxyProvider<T> proxyProvider, RetryPolicy defaultPolicy, Map<String, RetryPolicy> methodNameToPolicyMap) -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Returns the connection id associated with the InvocationHandler instance.protected ObjectinvokeMethod(Method method, Object[] args)
-
Field Details
-
LOG
public static final org.slf4j.Logger LOG -
SET_CALL_ID_FOR_TEST
-
-
Constructor Details
-
RetryInvocationHandler
-
RetryInvocationHandler
protected RetryInvocationHandler(FailoverProxyProvider<T> proxyProvider, RetryPolicy defaultPolicy, Map<String, RetryPolicy> methodNameToPolicyMap)
-
-
Method Details
-
invoke
- Specified by:
invokein interfaceInvocationHandler- Throws:
Throwable
-
invokeMethod
- Throws:
Throwable
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-
getConnectionId
Description copied from interface:RpcInvocationHandlerReturns the connection id associated with the InvocationHandler instance.- Specified by:
getConnectionIdin interfaceRpcInvocationHandler- Returns:
- ConnectionId
-
getProxyProvider
-