Function lock

Source
pub async fn lock(
    zookeeper: Arc<ZooKeeper>,
    path: String,
) -> ZkResult<Arc<LockGuard>>
Expand description

Fully distributed locks that are globally synchronous, meaning at any snapshot in time no two clients think they hold the same lock.