Module org.elasticsearch.server
Package org.elasticsearch.action.support
Class RefCountAwareThreadedActionListener<Response extends RefCounted>
java.lang.Object
org.elasticsearch.action.support.AbstractThreadedActionListener<Response>
org.elasticsearch.action.support.RefCountAwareThreadedActionListener<Response>
- All Implemented Interfaces:
ActionListener<Response>
public final class RefCountAwareThreadedActionListener<Response extends RefCounted>
extends AbstractThreadedActionListener<Response>
Same as
ThreadedActionListener
but for RefCounted
types. Makes sure to increment ref-count by one before forking
to another thread and decrementing after the forked task completes.-
Field Summary
Fields inherited from class org.elasticsearch.action.support.AbstractThreadedActionListener
delegate, executor, forceExecution
-
Constructor Summary
ConstructorsConstructorDescriptionRefCountAwareThreadedActionListener
(Executor executor, ActionListener<Response> delegate) -
Method Summary
Methods inherited from class org.elasticsearch.action.support.AbstractThreadedActionListener
onFailure, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.elasticsearch.action.ActionListener
delegateFailure, delegateFailureAndWrap, delegateResponse, map, safeMap
-
Constructor Details
-
RefCountAwareThreadedActionListener
-
-
Method Details
-
onResponse
Description copied from interface:ActionListener
Handle action response. This response may constitute a failure or a success but it is up to the listener to make that decision.
-