The ObjectName class contains a space optimization that causes pairs of integer values (lengths of keys and values) to be shared between different ObjectName instances. So for example, if two ObjectNames have keys and values with the same length, they will use the same objects to represent these pairs of integers. Unfortunately, access to the WeakHashMap that contains these integer pairs is not synchronized. So if two ObjectNames are created at the same time, the WeakHashMap may be modified by two threads concurrently and become corrupted. Thereafter, of course, further ObjectName creation is unlikely to work correctly either.