Class LatchedActionListener<T>

java.lang.Object
org.elasticsearch.action.LatchedActionListener<T>
All Implemented Interfaces:
ActionListener<T>

public class LatchedActionListener<T> extends Object implements ActionListener<T>
An action listener that allows passing in a CountDownLatch that will be counted down after onResponse or onFailure is called
  • Constructor Details

  • Method Details

    • onResponse

      public void onResponse(T t)
      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.
      Specified by:
      onResponse in interface ActionListener<T>
    • onFailure

      public void onFailure(Exception e)
      Description copied from interface: ActionListener
      A failure caused by an exception at some phase of the task.
      Specified by:
      onFailure in interface ActionListener<T>