code: protected void notifyListener(final ExecutorService executor,
      final Future<?> future, final GenericCompletionListener listener) {
      executor.submit(new Runnable() {
        @Override
        public void run() {
          try {
            listener.onComplete(future);
          } catch(Throwable t) {
            getLogger().warn(
              "Exception thrown wile executing " + listener.getClass().getName()
                + ".operationComplete()", t);
          }
        }
      });
    }
docs: Notify a specific listener of completion.
  
  @param executor the executor to use.
  @param future the future to hand over.
  @param listener the listener to notify.