Repository: phoenix
Updated Branches:
  refs/heads/4.0 16fbfa7ab -> ba3fa3424


PHOENIX-1562 NPE in ServerCacheClient


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/ba3fa342
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/ba3fa342
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/ba3fa342

Branch: refs/heads/4.0
Commit: ba3fa342476a668731f5ce767920a2efd8d36d85
Parents: 16fbfa7
Author: maryannxue <wei....@intel.com>
Authored: Mon Jan 12 17:48:55 2015 -0500
Committer: maryannxue <wei....@intel.com>
Committed: Mon Jan 12 17:48:55 2015 -0500

----------------------------------------------------------------------
 .../main/java/org/apache/phoenix/cache/ServerCacheClient.java    | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/phoenix/blob/ba3fa342/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
----------------------------------------------------------------------
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java 
b/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
index ba7d265..1233e1c 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
@@ -24,12 +24,12 @@ import java.io.IOException;
 import java.sql.SQLException;
 import java.util.ArrayList;
 import java.util.Collections;
-import java.util.HashMap;
 import java.util.HashSet;
 import java.util.List;
 import java.util.Map;
 import java.util.Random;
 import java.util.Set;
+import java.util.concurrent.ConcurrentHashMap;
 import java.util.concurrent.ExecutorService;
 import java.util.concurrent.Future;
 import java.util.concurrent.TimeUnit;
@@ -82,7 +82,7 @@ public class ServerCacheClient {
     private static final Log LOG = LogFactory.getLog(ServerCacheClient.class);
     private static final Random RANDOM = new Random();
     private final PhoenixConnection connection;
-    private final Map<Integer, TableRef> cacheUsingTableRefMap = new 
HashMap<Integer, TableRef>();
+    private final Map<Integer, TableRef> cacheUsingTableRefMap = new 
ConcurrentHashMap<Integer, TableRef>();
 
     /**
      * Construct client used to create a serialized cached snapshot of a table 
and send it to each region server

Reply via email to