ThreadLocal应用
乐观锁和悲观锁
缓存一致性协议
sleep方法
同步容器类
在Java8中,ConcurrentHashMap做了较大的调整。
``` The main reason that nulls aren’t allowed in ConcurrentMaps (ConcurrentHashMaps, ConcurrentSkipListMaps) is that ambiguities that may be just barely tolerable in non-concurrent maps can’t be accommodated. The main one is that if map.get(key) returns null, you can’t detect whether the key explicitly maps to null vs the key isn’t mapped. In a non-concurrent map, you can check this via map.contains(key), but in a concurrent one, the map might have changed between calls.
同步与异步/阻塞与非阻塞
synchronized基本使用 修饰普通方法
在类中定义的private static Class为静态内部类。