@Override
  public TSStatus operatePermission(final TAuthorizerReq req) {
    if (req.getAuthorType() < 0 || req.getAuthorType() >= AuthorType.values().length) {
      throw new IndexOutOfBoundsException("Invalid Author Type ordinal");
    }
    return configManager.operatePermission(
        new AuthorTreePlan(
            ConfigPhysicalPlanType.values()[
                req.getAuthorType() + ConfigPhysicalPlanType.CreateUser.ordinal()],
            req.getUserName(),
            req.getRoleName(),
            req.getPassword(),
            req.getNewPassword(),
            req.getPermissions(),
            req.isGrantOpt(),
            AuthUtils.deserializePartialPathList(ByteBuffer.wrap(req.getNodeNameList()))));
  }
ConfigNodeRPCServer exposes the interface that interacts with the DataNode
iotdb-core/confignode/src/main/java/org/apache/iotdb/confignode/service/thrift/ConfigNodeRPCServiceProcessor.java