Github user mkedwards commented on the issue:
https://github.com/apache/zookeeper/pull/707
I have pushed an incremental change which should address the lock inversion
scenario more completely, along with condition-variable-style waiting for the
quorum/election address to become non-null. (This proved a great deal simpler
than trying to use a ReentrantReadWriteLock to solve that problem.) Please
re-review.---
