public TSStatus removeConfigNode(
      TConfigNodeLocation configNodeLocation, SyncConfigNodeIServiceClient client)
      throws ClientManagerException, TException, InterruptedException {
    TSStatus status = client.removeConfigNode(configNodeLocation);
    while (status.getCode() == TSStatusCode.REDIRECTION_RECOMMEND.getStatusCode()) {
      TimeUnit.MILLISECONDS.sleep(2000);
      updateConfigNodeLeader(status);
      try (SyncConfigNodeIServiceClient clientLeader =
          clientManager.borrowClient(configNodeLeader)) {
        status = clientLeader.removeConfigNode(configNodeLocation);
      }
    }
    return status;
  }
ConfigNode Leader stop any ConfigNode in the cluster.

@param configNodeLocation To be removed ConfigNode
@throws ClientManagerException removeConfigNode
@throws TException removeConfigNode
@throws InterruptedException removeConfigNode
@return SUCCESS_STATUS: remove ConfigNode success, other status remove failed
iotdb-core/confignode/src/main/java/org/apache/iotdb/confignode/client/sync/SyncConfigNodeClientPool.java