mirror of https://github.com/apache/cassandra
Switch from NBHM to CHM in MessagingService's callback map
patch by Daniel Norberg; reviewed by jbellis for CASSANDRA-4708
This commit is contained in:
parent
19800189d7
commit
cad32377d7
|
|
@ -1,4 +1,5 @@
|
|||
1.0.12
|
||||
* Switch from NBHM to CHM in MessagingService's callback map, which
|
||||
* increase Xss to 160k to accomodate latest 1.6 JVMs (CASSANDRA-4602)
|
||||
* fix toString of hint destination tokens (CASSANDRA-4568)
|
||||
* (Hadoop) fix setting key length for old-style mapred api (CASSANDRA-4534)
|
||||
|
|
|
|||
|
|
@ -18,15 +18,17 @@
|
|||
|
||||
package org.apache.cassandra.utils;
|
||||
|
||||
import java.util.*;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
import java.util.Timer;
|
||||
import java.util.TimerTask;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
import java.util.concurrent.ConcurrentMap;
|
||||
|
||||
import com.google.common.base.Function;
|
||||
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import org.cliffc.high_scale_lib.NonBlockingHashMap;
|
||||
|
||||
public class ExpiringMap<K, V>
|
||||
{
|
||||
private static final Logger logger = LoggerFactory.getLogger(ExpiringMap.class);
|
||||
|
|
@ -57,7 +59,7 @@ public class ExpiringMap<K, V>
|
|||
}
|
||||
}
|
||||
|
||||
private final NonBlockingHashMap<K, CacheableObject<V>> cache = new NonBlockingHashMap<K, CacheableObject<V>>();
|
||||
private final ConcurrentMap<K, CacheableObject<V>> cache = new ConcurrentHashMap<K, CacheableObject<V>>();
|
||||
private final Timer timer;
|
||||
private static int counter = 0;
|
||||
private final long defaultExpiration;
|
||||
|
|
|
|||
Loading…
Reference in New Issue