code: protected void close() {
          _state = State.DISCONNECTED;
  
          shutdown();
  
          // remove the connection from map
          NetMgr.getInstance().dropConnection(InetSocketAddress.createUnresolved(_remoteHost, _port));
  
          // notify all the pending requests in the timeout map
          notifyAllPendingSenders("Channel closed, connection closing.");
      }
docs: This is called when the connection should be closed.