private void commitUnPartitionedTable() {
    if (!addFiles.isEmpty()) {
      final String newDataLocation = TableFileUtil.getFileDir(addFiles.get(0).path().toString());
      try {
        transactionalHMSClient.run(
            c -> {
              Table tbl = c.getTable(db, tableName);
              tbl.getSd().setLocation(newDataLocation);
              HiveTableUtil.generateTableProperties(commitTimestamp, addFiles)
                  .forEach((key, value) -> hiveTable.getParameters().put(key, value));
              c.alterTable(db, tableName, tbl);
              return 0;
            });
      } catch (TException | InterruptedException e) {
        throw new RuntimeException(e);
      }
    }
  }
check files in the partition, and delete orphan files
amoro-format-mixed/amoro-mixed-hive/src/main/java/org/apache/amoro/hive/op/ReplaceHivePartitions.java