public static List<String> getHivePartitionNames(
      HMSClientPool hiveClient, TableIdentifier tableIdentifier) {
    try {
      return hiveClient
          .run(
              client ->
                  client.listPartitionNames(
                      tableIdentifier.getDatabase(),
                      tableIdentifier.getTableName(),
                      Short.MAX_VALUE))
          .stream()
          .collect(Collectors.toList());
    } catch (NoSuchObjectException e) {
      throw new NoSuchTableException(
          e, "Hive table does not exist: %s", tableIdentifier.getTableName());
    } catch (TException e) {
      throw new RuntimeException("Failed to get partitions " + tableIdentifier.getTableName(), e);
    } catch (InterruptedException e) {
      Thread.currentThread().interrupt();
      throw new RuntimeException("Interrupted in call to listPartitions", e);
    }
  }
Gets all partition names of the Hive table.

@param hiveClient Hive client from MixedHiveCatalog
@param tableIdentifier A table identifier
@return A List of Hive partition names
amoro-format-mixed/amoro-mixed-hive/src/main/java/org/apache/amoro/hive/utils/HivePartitionUtil.java