libkv icon indicating copy to clipboard operation
libkv copied to clipboard

Zookeeper: Relinquish locks on session close

Open convergentio opened this issue 7 years ago • 1 comments

The zookeeper store implements locking by using ephermeral nodes. On session close, all ephemeral nodes created by a client are removed, which means that other clients can acquire the lock.

Previously, the zookeeper store failed to notify clients that the lock had been relinquished due to the session being closed (due to expiration or otherwise). Which means that the clients would continue execution while believing (wrongfully) that they still hold the lock.

Now, the zookeeper store monitors the state of the session and notifies clients that the lock has been lost when the session is closed.

Signed-off-by: Daniel Ferstay [email protected]

convergentio avatar Mar 17 '17 22:03 convergentio

The CI failure is fixed by https://github.com/docker/libkv/pull/154

convergentio avatar Mar 21 '17 19:03 convergentio