java - In ZooKeeper, is there a way to write a hierarchy atomically without implementing distributed locks yourself? -


let's want write out tree zookeeper

.            .           / \ .          b   c .         / \ .        d   e 

some other client come along , delete node b right after create before i'm able write node 'd' or 'e'.

is there way can write hierarchy atomically, or possibly lock path?

you can use new multi() api

it completes operations or aborts them all.


Comments

Popular posts from this blog

jasper reports - Fixed header in Excel using JasperReports -

media player - Android: mediaplayer went away with unhandled events -

python - ('The SQL contains 0 parameter markers, but 50 parameters were supplied', 'HY000') or TypeError: 'tuple' object is not callable -