Commit b90e4164 by 张乐 Committed by GitHub

Merge pull request #333 from nobodyiam/fix-java-7

change to ConcurrentMap to use putIfAbsent method in java 1.7
parents 562bc959 5b1a9021
...@@ -41,6 +41,7 @@ import java.lang.reflect.Type; ...@@ -41,6 +41,7 @@ import java.lang.reflect.Type;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import java.util.Random; import java.util.Random;
import java.util.concurrent.ConcurrentMap;
import java.util.concurrent.ExecutorService; import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors; import java.util.concurrent.Executors;
import java.util.concurrent.TimeUnit; import java.util.concurrent.TimeUnit;
...@@ -62,7 +63,7 @@ public class RemoteConfigLongPollService implements Initializable { ...@@ -62,7 +63,7 @@ public class RemoteConfigLongPollService implements Initializable {
private RateLimiter m_longPollRateLimiter; private RateLimiter m_longPollRateLimiter;
private final AtomicBoolean m_longPollStarted; private final AtomicBoolean m_longPollStarted;
private final Multimap<String, RemoteConfigRepository> m_longPollNamespaces; private final Multimap<String, RemoteConfigRepository> m_longPollNamespaces;
private final Map<String, Long> m_notifications; private final ConcurrentMap<String, Long> m_notifications;
private Type m_responseType; private Type m_responseType;
private Gson gson; private Gson gson;
@Inject @Inject
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment