code: @Override
      public void disconnect() {
          if (future != null) {
              try {
                  // session will be null if connect failed
                  if (session != null) {
                      // close, now
                      CloseFuture closeFuture = session.closeNow();
                      // now wait for the close to be completed
                      if (closeFuture.await(1000, TimeUnit.MILLISECONDS)) {
                          if (!future.isCanceled()) {
                              if (future.cancel()) {
                                  log.debug("Connect future cancelled after close future");
                              }
                          }
                      }
                  } else if (future.cancel()) {
                      log.debug("Connect future cancelled");
                  }
              } catch (Exception e) {
                  log.warn("Exception during disconnect", e);
              } finally {
                  // we can now dispose the connector
                  socketConnector.dispose(false);
              }
          }
          super.disconnect();
      }
docs: {@inheritDoc}