Problem
For highly partitioned Hive tables, FE planning may enumerate every HMS partition name before applying selective partition predicates. This makes planning latency depend on a full metastore listing and can cause timeouts.
Proposal
Materialize safe equality and IN partition predicates through HMS get_partitions_by_filter before the generic selected-partition map is built. Keep the existing local full-list pruning path as a compatibility fallback when the HMS filter API or dialect is unavailable.
Expected benefit
Selective partition queries avoid the full partition-name enumeration on the planner path when HMS supports the filter API.
Problem
For highly partitioned Hive tables, FE planning may enumerate every HMS partition name before applying selective partition predicates. This makes planning latency depend on a full metastore listing and can cause timeouts.
Proposal
Materialize safe equality and IN partition predicates through HMS
get_partitions_by_filterbefore the generic selected-partition map is built. Keep the existing local full-list pruning path as a compatibility fallback when the HMS filter API or dialect is unavailable.Expected benefit
Selective partition queries avoid the full partition-name enumeration on the planner path when HMS supports the filter API.