[concurrency-interest] Handling Null Values in ConcurrentHashMap
chakritsus at yahoo.com
Fri May 12 06:01:45 EDT 2006
I would like to replace some Hashmaps in our
application, which are prone to multi threading issues
Currently we keep null key and values in hashmap
without any issues as HashMap allows them.
But ConcurrentHashMap does not allow any null key and
I would like to know whether anybody is following any
general practice to tackle this issue .
It is very difficult to check for null keys and values
in my entire application .
I thought of writing a wrapper around
ConcurrentHashMap which will mask and unmask key and
values with some other object, when null values are
getting inserted .
But the issue is that in certain bulk operations like
keySet() , values() etc, it is very difficult unmask
If anybody has ideas in resolving this kind of issue,
Please let me know.
It would be helpful to us .
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
More information about the Concurrency-interest