HashMap | ConcurrentHashMap |
Not Thread safe | Thread safe |
Performance is High | Relatively Performance is low |
While iterating other threads not allowed to modify and will not ConcurrentModificationException | While iterating other threads are allowed to modify no exceptions thrown |
Iterator is FailFast | Iterator is fail safe |
Null is allowed for both keys are values | Null is not allowed in both keys and values |
Introduced with java 1.2 verion | Introduced with Java 1.6 version |