dengzhhu653 commented on code in PR #3599:
URL: https://github.com/apache/hive/pull/3599#discussion_r1672303577


##########
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/HMSHandler.java:
##########
@@ -5503,15 +5692,34 @@ public Partition get_partition_with_auth(final String 
db_name,
   @Override
   @Deprecated
   public List<Partition> get_partitions(final String db_name, final String 
tbl_name,
-                                        final short max_parts) throws 
NoSuchObjectException, MetaException {
+      final short max_parts) throws NoSuchObjectException, MetaException {
     return get_partitions(db_name, tbl_name,
         new 
GetPartitionsArgs.GetPartitionsArgsBuilder().max(max_parts).build());
   }
 
   private List<Partition> get_partitions(final String db_name, final String 
tbl_name,
     GetPartitionsArgs args) throws NoSuchObjectException, MetaException {
     String[] parsedDbName = parseDbName(db_name, conf);
-    startTableFunction("get_partitions", parsedDbName[CAT_NAME], 
parsedDbName[DB_NAME], tbl_name);
+    List<Partition> ret = null;
+    Exception ex = null;
+    try {
+      PartitionsRequest req = new PartitionsRequest(parsedDbName[DB_NAME], 
tbl_name);
+      req.setCatName(parsedDbName[CAT_NAME]);
+      req.setMaxParts((short)args.getMax());

Review Comment:
   nit: could the `args` have something else configured to get the partitions? 
such as the include key



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org
For additional commands, e-mail: gitbox-h...@hive.apache.org

Reply via email to