phoenix-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] BinShi-SecularBird commented on a change in pull request #425: PHOENIX-5069 Use asynchronous refresh to provide non-blocking Phoenix Stats Client Cache
Date Fri, 18 Jan 2019 18:58:09 GMT
BinShi-SecularBird commented on a change in pull request #425: PHOENIX-5069 Use asynchronous
refresh to provide non-blocking Phoenix Stats Client Cache
URL: https://github.com/apache/phoenix/pull/425#discussion_r249150888
 
 

 ##########
 File path: phoenix-core/src/main/java/org/apache/phoenix/query/GuidePostsCache.java
 ##########
 @@ -85,39 +106,54 @@ public GuidePostsCache(ConnectionQueryServices queryServices, Configuration
conf
                 })
                 // Log removals at TRACE for debugging
                 .removalListener(new PhoenixStatsCacheRemovalListener())
-                // Automatically load the cache when entries are missing
-                .build(isStatsEnabled ? new StatsLoader() : new EmptyStatsLoader());
+                // Automatically load the cache when entries need to be refreshed
+                .build(cacheLoader);
     }
 
     /**
-     * {@link CacheLoader} implementation for the Phoenix Table Stats cache.
+     * {@link PhoenixStatsLoader} implementation for the Stats Loader.
      */
-    protected class StatsLoader extends CacheLoader<GuidePostsKey, GuidePostsInfo>
{
+    protected class StatsLoaderImpl implements PhoenixStatsLoader {
 
 Review comment:
   I only made very trivial changes in this inner class StatsLoaderImpl. Adding unit test
for StatsLoaderImpl shouldn't be addressed by this change.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message