wecharyu opened a new pull request, #5198:
URL: https://github.com/apache/hive/pull/5198

   ### What changes were proposed in this pull request?
   
   When `hive.metastore.limit.partition.request` is configured, HMS would get 
the matched partition counts before getting the real partition objects. The 
count operation could be a slow query if the input filter or expr is too 
complex, and such slow filter will be executed twice.
   We can make an improvement by the new steps:
   1. get matched partition names firstly, 
   2. then check limit through the size of partition names,
   3.  finally get the partitions by the partition names.
   
   ### Why are the changes needed?
   To reduce the slow filter execute times.
   
   ### Does this PR introduce _any_ user-facing change?
   No.
   
   ### Is the change a dependency upgrade?
   No.
   
   ### How was this patch tested?
   Add unit test and benchmark test.


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to