docs: public final void dispatchEvent(Set<SelectionKey> selectedKeySet) {
      Iterator<SelectionKey> it = selectedKeySet.iterator();
      boolean skipOpRead = false;
      while (it.hasNext()) {
        SelectionKey key = it.next();
        it.remove();
        if (!key.isValid()) {
          if (key.attachment() != null) {
            controller.closeSelectionKey(key);
          } else {
            key.cancel();
          }
          continue;
        }
        try {
          if (key.isValid() && key.isAcceptable()) {
            controller.onAccept(key);
            continue;
          }
          if (key.isValid() && (key.readyOps() & SelectionKey.OP_WRITE) == SelectionKey.OP_WRITE) {
            // Remove write interest
            key.interestOps(key.interestOps() & ~SelectionKey.OP_WRITE);
            controller.onWrite(key);
            if (!controller.isHandleReadWriteConcurrently()) {
              skipOpRead = true;
            }
          }
          if (!skipOpRead && key.isValid()
              && (key.readyOps() & SelectionKey.OP_READ) == SelectionKey.OP_READ) {
            key.interestOps(key.interestOps() & ~SelectionKey.OP_READ);
            if (!controller.getStatistics().isReceiveOverFlow()) {
              // Remove read interest
              controller.onRead(key);
            } else {
              key.interestOps(key.interestOps() | SelectionKey.OP_READ);
            }
  
          }
          if ((key.readyOps() & SelectionKey.OP_CONNECT) == SelectionKey.OP_CONNECT) {
            controller.onConnect(key);
          }
  
        } catch (CancelledKeyException e) {
          // ignore
        } catch (RejectedExecutionException e) {
  
          if (key.attachment() instanceof AbstractNioSession) {
            ((AbstractNioSession) key.attachment()).onException(e);
          }
          controller.notifyException(e);
          if (selector.isOpen()) {
            continue;
          } else {
            break;
          }
        } catch (Exception e) {
          if (key.attachment() instanceof AbstractNioSession) {
            ((AbstractNioSession) key.attachment()).onException(e);
          }
          controller.closeSelectionKey(key);
          controller.notifyException(e);
          log.error("Reactor dispatch events error", e);
          if (selector.isOpen()) {
            continue;
          } else {
            break;
          }
        }
      }
    }