@SuppressWarnings({ "FutureReturnValueIgnored", "rawtypes", "unchecked" })
  public static <V> void addListener(Future<V> future,
    GenericFutureListener<? extends Future<? super V>> listener) {
    future.addListener(f -> {
      try {
        // the ? operator in template makes it really hard to pass compile, so here we just cast the
        // listener to raw type.
        ((GenericFutureListener) listener).operationComplete(f);
      } catch (Throwable t) {
        LOG.error("Unexpected error caught when processing netty", t);
      }
    });
  }
This is method is used when you just want to add a listener to the given netty future. Ignoring
the return value of a Future is considered as a bad practice as it may suppress exceptions
thrown from the code that completes the future, and this method will catch all the exception
thrown from the {@code listener} to catch possible code bugs.
<p/>
And the error phone check will always report FutureReturnValueIgnored because every method in
the {@link Future} class will return a new {@link Future}, so you always have one future that
has not been checked. So we introduce this method and add a suppress warnings annotation here.
hbase-common/src/main/java/org/apache/hadoop/hbase/util/NettyFutureUtils.java