[
https://issues.apache.org/jira/browse/HIVE-21202?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16758569#comment-16758569
]
Vihang Karajgaonkar commented on HIVE-21202:
--------------------------------------------
yeah, most likely this API doesn't implement directSQL which is why its slow.
If the Hive authorization is not needed, the work-around is to use the other
partition fetch APIs which you mentioned above.
> get_partitions_ps_with_auth() takes a long time with high number of partitions
> ------------------------------------------------------------------------------
>
> Key: HIVE-21202
> URL: https://issues.apache.org/jira/browse/HIVE-21202
> Project: Hive
> Issue Type: Bug
> Affects Versions: 2.1.1
> Reporter: Sakshi Bansal
> Priority: Major
>
>
> On a table with 6000 partitions,
> `get_partitions_ps_with_auth` takes around 130 seconds to fetch a list of
> partitions.
>
> {noformat}
> HiveMetaStore::public List<Partition> get_partitions_ps_with_auth(final
> String db_name,
> final String tbl_name, final List<String> part_vals,
> final short max_parts, final String userName,
> final List<String> groupNames)
> {noformat}
>
> Whereas, a combination of the following 2 APIs takes only 5 seconds in total.
>
> {noformat}
> HiveMetaStore::public List<String> get_partition_names_ps(final String
> db_name,
> final String tbl_name, final List<String> part_vals, final short max_parts)
> HiveMetaStore::public List<Partition> get_partitions_by_names(final String
> dbName,
> final String tblName, final List<String> partNames)
> {noformat}
>
> Note: Hive authorization is not enabled.
> Please close as duplicate of
> https://issues.apache.org/jira/browse/HIVE-19715, if it aims at solving this
> problem as well.
>
>
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)