kevinwilfong has commented on the revision "
HIVE-2907 [jira] Hive error when dropping a table with large number of partitions".
This looks really good, thanks for the code clean up, just some small comments.
metastore/src/java/org/apache/hadoop/hive/metastore/HiveAlterHandler.java:164 It'd be great if we could use the same config here, otherwise alter table will face the same memory issues for tables with lots of partitions.
This could be a separate task too.
metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java:1399-1401 If any client code already assumes that if 0 is max, it returns all partitions, which, given the code in HiveAlterHandler, seems possible, this will break that code. Could we treat 0 as infinity as well?
metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java:1565-1567 Same here regarding 0 => infinity
metastore/src/test/org/apache/hadoop/hive/metastore/TestHiveMetaStore.java:1997 Can you remove this line if it's not needed.
metastore/src/test/org/apache/hadoop/hive/metastore/TestHiveMetaStore.java:544 Shouldn't this be "table should not have existed"
common/src/java/org/apache/hadoop/hive/conf/HiveConf.java:292 Could you add a testcase, where you set this really low, e.g. 1, and you drop a table with multiple partitions.
Also, could you add a similar test where you make one of the partitions NO_DROP, and make sure it fails.