curator-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cameron McKenzie <mckenzie....@gmail.com>
Subject Re: Update the znode data using curator?
Date Wed, 08 Jan 2014 23:16:05 GMT
CuratorFramework client = ...
client.setData().forPath("/my/example/hello",
"new-data-inserted".getBytes());


On Thu, Jan 9, 2014 at 9:25 AM, Check Peck <comptechgeeky@gmail.com> wrote:

> Is there any way to update the znode data using Curator.
>
>     CuratorFramework client = CuratorClient.createSimple("localhost:2181");
>     client.start();
>
> Suppose if the node (/my/example/hello) already exists and we just need to
> update the znode data. Do I need to execute the below code again just to
> update the data using curator?
>
>     client.create().creatingParentsIfNeeded().forPath("/my/example/hello",
> "new-data-inserted".getBytes());
>
> or is there some better API for that?
>

Mime
View raw message