Package org.apache.hadoop.hbase.client
Class RetryingCallerInterceptorContext
java.lang.Object
org.apache.hadoop.hbase.client.RetryingCallerInterceptorContext
- Direct Known Subclasses:
FastFailInterceptorContext,NoOpRetryingInterceptorContext
The context object used in the
RpcRetryingCaller to enable
RetryingCallerInterceptor to intercept calls. RetryingCallerInterceptorContext is
the piece of information unique to a retrying call that transfers information from the call into
the RetryingCallerInterceptor so that RetryingCallerInterceptor can take
appropriate action according to the specific logic-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract voidclear()This function clears the internal state of the context object.abstract RetryingCallerInterceptorContextprepare(RetryingCallable<?> callable) This prepares the context object by populating it with information specific to the implementation of theRetryingCallerInterceptoralong with which this will be used.abstract RetryingCallerInterceptorContextprepare(RetryingCallable<?> callable, int tries) Telescopic extension that takes which of the many retries we are currently in.
-
Constructor Details
-
RetryingCallerInterceptorContext
protected RetryingCallerInterceptorContext()
-
-
Method Details
-
clear
This function clears the internal state of the context object. -
prepare
This prepares the context object by populating it with information specific to the implementation of theRetryingCallerInterceptoralong with which this will be used. : TheRetryingCallablethat contains the information about the call that is being made.- Returns:
- A new
RetryingCallerInterceptorContextobject that can be used for use in the current retrying call
-
prepare
Telescopic extension that takes which of the many retries we are currently in. : TheRetryingCallablethat contains the information about the call that is being made. : The retry number that we are currently in.- Returns:
- A new context object that can be used for use in the current retrying call
-