Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ZOOKEEPER-3652: Synchronize ClientCnxn outgoing queue flush on a stab…
…le internal value When packets are added to ClientCnxn's outgoing packet queue we ensure there's no conflict with an ongoing flush of that queue because of connection loss. Synchronization used to be on the state field's value. This value is both not stable (its value changes over time), possibly causing improper synchronization, and global, which can cause contention in applications that run several ZooKeeper clients. We now synchronize on outgoingQueue which is both local to a ClientCnxn's instance and stable.
- Loading branch information