private List<Peer> createConsensusPipes(Set<Peer> peers) {
    return peers.stream()
        .filter(
            peer -> {
              try {
                if (!peers.equals(thisNode)) {
                  consensusPipeManager.createConsensusPipe(thisNode, peer);
                }
                return true;
              } catch (Exception e) {
                LOGGER.warn(
                    "{}: cannot create consensus pipe between {} and {}",
                    e.getMessage(),
                    thisNode,
                    peer,
                    e);
                return false;
              }
            })
        .collect(Collectors.toList());
  }
PipeConsensusServerImpl is a consensus server implementation for pipe consensus.
iotdb-core/consensus/src/main/java/org/apache/iotdb/consensus/pipe/PipeConsensusServerImpl.java