From 693c493efe3603db90cec6e7e2cd66f6d834e11e Mon Sep 17 00:00:00 2001 From: Khuwnchai J Date: Mon, 13 Jun 2022 00:31:36 +0700 Subject: [PATCH] Minor formatting --- .../metastore/AWSCatalogMetastoreClient.java | 26 ++++++++----------- 1 file changed, 11 insertions(+), 15 deletions(-) diff --git a/aws-glue-datacatalog-spark-client/src/main/java/com/amazonaws/glue/catalog/metastore/AWSCatalogMetastoreClient.java b/aws-glue-datacatalog-spark-client/src/main/java/com/amazonaws/glue/catalog/metastore/AWSCatalogMetastoreClient.java index ab29cd96..9cfb961e 100644 --- a/aws-glue-datacatalog-spark-client/src/main/java/com/amazonaws/glue/catalog/metastore/AWSCatalogMetastoreClient.java +++ b/aws-glue-datacatalog-spark-client/src/main/java/com/amazonaws/glue/catalog/metastore/AWSCatalogMetastoreClient.java @@ -678,22 +678,21 @@ public boolean dropPartition(String dbName, String tblName, List values, return glueMetastoreClientDelegate.dropPartition(dbName, tblName, values, options.ifExists, options.deleteData, options.purgeData); } + @Override + public boolean dropPartition(String dbName, String tblName, String partitionName, boolean deleteData) + throws NoSuchObjectException, MetaException, TException { + List values = partitionNameToVals(partitionName); + return glueMetastoreClientDelegate.dropPartition(dbName, tblName, values, false, deleteData, false); + } + @Override public List dropPartitions( String dbName, String tblName, List> partExprs, boolean deleteData, - boolean ifExists - ) throws NoSuchObjectException, MetaException, TException { - throw new UnsupportedOperationException("dropPartitions is not supported"); - } - - @Override - public boolean dropPartition(String dbName, String tblName, String partitionName, boolean deleteData) - throws NoSuchObjectException, MetaException, TException { - List values = partitionNameToVals(partitionName); - return glueMetastoreClientDelegate.dropPartition(dbName, tblName, values, false, deleteData, false); + boolean ifExists) throws NoSuchObjectException, MetaException, TException { + return dropPartitions_core(dbName, tblName, partExprs, deleteData, false); } @Override @@ -1553,11 +1552,8 @@ public boolean isSameConfObj(HiveConf hiveConf) { } @Override - public boolean cacheFileMetadata( - String dbName, - String tblName, - String partName, - boolean allParts) throws TException { + public boolean cacheFileMetadata(String dbName, String tblName, String partName, boolean allParts) + throws TException { return glueMetastoreClientDelegate.cacheFileMetadata(dbName, tblName, partName, allParts); }