I am using in my code at the moment a ReentrantReadWriteLock to synchronize access over a tree-like structure. This structure is large, and read by many threads at once wit
Java 8 now has a java.util.concurrent.locks.StampedLock with a tryConvertToWriteLock(long) API
java.util.concurrent.locks.StampedLock
tryConvertToWriteLock(long)
More info at http://www.javaspecialists.eu/archive/Issue215.html