java.util.concurrent.ConcurrentHashMap keySet has null values
761993Mar 29 2010 — edited Dec 13 2010Hi,
This is jrockit version :
BEA JRockit(R) (build R27.3.1-1_CR344434-89345-1.5.0_11-20070925-1628-linux-ia32
, compiled mode)
running on wls10Mp1.
App puts, gets and removes keys from the ConcurrentHashMap instance across different threads:
Get the following exception sometimes :
Exception in thread "T1" java.lang.NullPointerException
at java.util.concurrent.ConcurrentHashMap.hash(ConcurrentHashMap.java:157)
at java.util.concurrent.ConcurrentHashMap.get(ConcurrentHashMap.java:730)
at my.app.class...
The get is based on a Iterator over keySet of ConcurrentHashMap.
App for sure doesn't put any null keys in ConcurrentHashMap.
What could be causing this ?
Thanx,