@Override public synchronized CompletableFuture<Void> disconnect(){
  closeFuture=new CompletableFuture<>();
  if (!consumers.isEmpty()) {
    consumers.forEach(null);
    if (havePendingRead && cursor.cancelPendingReadRequest()) {
      havePendingRead=false;
    }
  }
 else {
    closeFuture.complete(null);
  }
  return closeFuture;
}

@ Override public synchronized CompletableFuture < Void > disconnect ( ) { closeFuture = new CompletableFuture < > ( ) ; if ( ! consumers . isEmpty ( ) ) { consumers . forEach ( null ) ; if ( havePendingRead && cursor . cancelPendingReadRequest ( ) ) { havePendingRead = false ; } } else { closeFuture . complete ( null ) ; } return closeFuture ; }
disconnect all consumers on this dispatcher ( server side close ) . this triggers channelinactive on the inbound handler which calls dispatcher . removeconsumer ( ) , where the closefuture is completed
