public static List<Partition> getHiveAllPartitions(
      HMSClientPool hiveClient, TableIdentifier tableIdentifier) {
    try {
      return hiveClient.run(
          client ->
              client.listPartitions(
                  tableIdentifier.getDatabase(), tableIdentifier.getTableName(), Short.MAX_VALUE));
    } 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 partitions object of the Hive table.

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