From: Andrew Dinn <[email protected]>
> I have to ask the obvious: Why does the question matter?

I'm trying to figure out if something is a bug in HashMap in the JDK, or in 
Weld :D

The case in question is basically, a HashMap is created, and then the keys are 
iterated over concurrently.
The issue here though is that the HashMap is used as the backing of a MultiMap, 
and the multimap.get is basically hashmap.computeIfAbsent(key, k -> new 
HashSet()).
Meaning you have a HashMap, which you've fully initialized, and you're 
iterating over all the known keys in the map... but surprisingly the call to 
.get actually changes the structure of the map, leading to bad consequences.

/Michael

Reply via email to