It depends on how you use it in the application.
If you do a lot of reading and writing on it, ConcurrentHashMap is probably the best choice, if it mainly reads, a shared card wrapped in a collection using ReadWriteLock (since records will not be distributed, you will get quick access and lock only when writing).
Collections.synchronizedMap () is arguably the worst case scenario, as it can just give you a wrapper with all synchronized methods, avoiding it at all costs.
source share