Module org.elasticsearch.server
Package org.elasticsearch.action.support
Class AdapterActionFuture<T,L>
java.lang.Object
org.elasticsearch.common.util.concurrent.BaseFuture<T>
org.elasticsearch.action.support.AdapterActionFuture<T,L>
- All Implemented Interfaces:
Future<T>,ActionFuture<T>,ActionListener<L>
- Direct Known Subclasses:
ListenableActionFuture,PlainActionFuture
public abstract class AdapterActionFuture<T,L>
extends BaseFuture<T>
implements ActionFuture<T>, ActionListener<L>
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.action.ActionListener
ActionListener.Delegating<Response,DelegateResponse>, ActionListener.DelegatingActionListener<T>, ActionListener.DelegatingFailureActionListener<T, R>, ActionListener.MappedActionListener<Response, MappedResponse>, ActionListener.RunAfterActionListener<T>, ActionListener.RunBeforeActionListener<T> -
Field Summary
Fields inherited from interface org.elasticsearch.action.ActionListener
NOOP -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionSimilar toFuture.get(), just catching theInterruptedExceptionand throwing anIllegalStateExceptioninstead.actionGet(long timeoutMillis) Similar toFuture.get(long, java.util.concurrent.TimeUnit), just catching theInterruptedExceptionand throwing anIllegalStateExceptioninstead.Similar toFuture.get(long, java.util.concurrent.TimeUnit), just catching theInterruptedExceptionand throwing anIllegalStateExceptioninstead.Similar toFuture.get(long, java.util.concurrent.TimeUnit), just catching theInterruptedExceptionand throwing anIllegalStateExceptioninstead.Similar toFuture.get(long, java.util.concurrent.TimeUnit), just catching theInterruptedExceptionand throwing anIllegalStateExceptioninstead.protected abstract TvoidA failure caused by an exception at some phase of the task.voidonResponse(L result) Handle action response.Methods inherited from class org.elasticsearch.common.util.concurrent.BaseFuture
blockingAllowed, cancel, done, get, get, interruptTask, isCancelled, isDone, set, setExceptionMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.elasticsearch.action.ActionListener
delegateFailure, delegateResponse, map
-
Constructor Details
-
AdapterActionFuture
public AdapterActionFuture()
-
-
Method Details
-
actionGet
Description copied from interface:ActionFutureSimilar toFuture.get(), just catching theInterruptedExceptionand throwing anIllegalStateExceptioninstead. Also catchesExecutionExceptionand throws the actual cause instead.- Specified by:
actionGetin interfaceActionFuture<T>
-
actionGet
Description copied from interface:ActionFutureSimilar toFuture.get(long, java.util.concurrent.TimeUnit), just catching theInterruptedExceptionand throwing anIllegalStateExceptioninstead. Also catchesExecutionExceptionand throws the actual cause instead.- Specified by:
actionGetin interfaceActionFuture<T>
-
actionGet
Description copied from interface:ActionFutureSimilar toFuture.get(long, java.util.concurrent.TimeUnit), just catching theInterruptedExceptionand throwing anIllegalStateExceptioninstead. Also catchesExecutionExceptionand throws the actual cause instead.- Specified by:
actionGetin interfaceActionFuture<T>- Parameters:
timeoutMillis- Timeout in millis
-
actionGet
Description copied from interface:ActionFutureSimilar toFuture.get(long, java.util.concurrent.TimeUnit), just catching theInterruptedExceptionand throwing anIllegalStateExceptioninstead. Also catchesExecutionExceptionand throws the actual cause instead.- Specified by:
actionGetin interfaceActionFuture<T>
-
actionGet
Description copied from interface:ActionFutureSimilar toFuture.get(long, java.util.concurrent.TimeUnit), just catching theInterruptedExceptionand throwing anIllegalStateExceptioninstead. Also catchesExecutionExceptionand throws the actual cause instead.- Specified by:
actionGetin interfaceActionFuture<T>
-
onResponse
Description copied from interface:ActionListenerHandle action response. This response may constitute a failure or a success but it is up to the listener to make that decision.- Specified by:
onResponsein interfaceActionListener<T>
-
onFailure
Description copied from interface:ActionListenerA failure caused by an exception at some phase of the task.- Specified by:
onFailurein interfaceActionListener<T>
-
convert
-