ReentrantReadWriteLock
-
ReentrantReadWriteLockStaticPL/JAVA 2020. 2. 27. 11:48
1. Overview 2. ReentrantReadWriteLock 2.1 Why Multiple threads can safely read from a shared resource concurrently as long as they are not modifying its state. 2.2 Usage Synchronized and ReentrantLock do not allow multiple readers to access a shared resource concurrently. Not a big problem in the general case If we keep the critical sections short, the chances of contention over a lock are minim..