sam-an-cloudera commented on a change in pull request #662: Hive-21787:
Metastore table cache enhancement
URL: https://github.com/apache/hive/pull/662#discussion_r292212675
##########
File path:
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/cache/CachedStore.java
##########
@@ -404,8 +407,7 @@ public static long updateUsingNotificationEvents(RawStore
rawStore, long lastEve
/**
* This initializes the caches in SharedCache by getting the objects from
Metastore DB via
* ObjectStore and populating the respective caches
- */
- static void prewarm(RawStore rawStore) {
+ */ static void prewarm(RawStore rawStore) {
if (isCachePrewarmed.get()) {
Review comment:
That's a good idea. I think I can handle that in a follow up ticket. The way
we keep track of total memory size with LRU has changed, so that we don't
immediately know whether the cache is full. Old code used to keep the current
size and total size, and compare the two. I removed these two, since LRU tracks
weights internally. To stop populating further in prewarm, I think I need to
pass in the prewarm flag to SharedCache, and then in RemovalListener to check
if we are in prewarm, we stop population. Since it's async, it can be a bit
convoluted. Let me think it over and handle in a separate ticket. Track it
here. https://issues.apache.org/jira/browse/HIVE-21855
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]