You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@zookeeper.apache.org by Tassos Souris <ta...@yahoo.gr> on 2011/10/15 09:49:55 UTC

pzxid field in stat structure

Hi! what's the pzxid field in the stat structure for? couldn't find any information in the programmer's guide...

Re: pzxid field in stat structure

Posted by Benjamin Reed <br...@apache.org>.
the pzxid from the users point of view is purely informational.
internally we use it to figure out if we need to trigger watches on
reconnect.

both the pzxid and the cversion are updated when adding or removing children.

ben

On Tue, Oct 18, 2011 at 10:32 AM, Ted Dunning <te...@gmail.com> wrote:
> Good question.
>
> One thought is that you can use the multi for this except that I don't know if the parent version changes when adding or removing a child.  On the other hand you could also update the content of the parent in the same multi to free the version update.
>
> Sent from my iPhone
>
> On Oct 18, 2011, at 9:48, Dan Mihai Dumitriu <da...@midokura.com> wrote:
>
>> That brings up a question I was asking myself.  Why are there not
>> crate and delete methods which optionally require the parent's
>> children version? (i.e. optimistic concurrency control for the
>> creation and deletion of nodes)
>>
>> Cheers,
>> Dan
>>
>>
>> On Sun, Oct 16, 2011 at 8:59 AM, Mahadev Konar <ma...@hortonworks.com> wrote:
>>> Hi Tassos,
>>>  There is some documention in src/zookeeper.jute:
>>>
>>>  long pzxid;      // last modified children
>>>
>>> But, we should probably add some documentation in the programmer's
>>> guide. Can you please open  a jira/upload a patch :)?
>>>
>>> thanks
>>> mahadev
>>>
>>> On Sat, Oct 15, 2011 at 12:49 AM, Tassos Souris <ta...@yahoo.gr> wrote:
>>>> Hi! what's the pzxid field in the stat structure for? couldn't find any information in the programmer's guide...
>>>>
>>>
>

Re: pzxid field in stat structure

Posted by Ted Dunning <te...@gmail.com>.
Good question. 

One thought is that you can use the multi for this except that I don't know if the parent version changes when adding or removing a child.  On the other hand you could also update the content of the parent in the same multi to free the version update.  

Sent from my iPhone

On Oct 18, 2011, at 9:48, Dan Mihai Dumitriu <da...@midokura.com> wrote:

> That brings up a question I was asking myself.  Why are there not
> crate and delete methods which optionally require the parent's
> children version? (i.e. optimistic concurrency control for the
> creation and deletion of nodes)
> 
> Cheers,
> Dan
> 
> 
> On Sun, Oct 16, 2011 at 8:59 AM, Mahadev Konar <ma...@hortonworks.com> wrote:
>> Hi Tassos,
>>  There is some documention in src/zookeeper.jute:
>> 
>>  long pzxid;      // last modified children
>> 
>> But, we should probably add some documentation in the programmer's
>> guide. Can you please open  a jira/upload a patch :)?
>> 
>> thanks
>> mahadev
>> 
>> On Sat, Oct 15, 2011 at 12:49 AM, Tassos Souris <ta...@yahoo.gr> wrote:
>>> Hi! what's the pzxid field in the stat structure for? couldn't find any information in the programmer's guide...
>>> 
>> 

Re: pzxid field in stat structure

Posted by Dan Mihai Dumitriu <da...@midokura.com>.
That brings up a question I was asking myself.  Why are there not
crate and delete methods which optionally require the parent's
children version? (i.e. optimistic concurrency control for the
creation and deletion of nodes)

Cheers,
Dan


On Sun, Oct 16, 2011 at 8:59 AM, Mahadev Konar <ma...@hortonworks.com> wrote:
> Hi Tassos,
>  There is some documention in src/zookeeper.jute:
>
>  long pzxid;      // last modified children
>
> But, we should probably add some documentation in the programmer's
> guide. Can you please open  a jira/upload a patch :)?
>
> thanks
> mahadev
>
> On Sat, Oct 15, 2011 at 12:49 AM, Tassos Souris <ta...@yahoo.gr> wrote:
>> Hi! what's the pzxid field in the stat structure for? couldn't find any information in the programmer's guide...
>>
>

Re: pzxid field in stat structure

Posted by Mahadev Konar <ma...@hortonworks.com>.
Hi Tassos,
 There is some documention in src/zookeeper.jute:

 long pzxid;      // last modified children

But, we should probably add some documentation in the programmer's
guide. Can you please open  a jira/upload a patch :)?

thanks
mahadev

On Sat, Oct 15, 2011 at 12:49 AM, Tassos Souris <ta...@yahoo.gr> wrote:
> Hi! what's the pzxid field in the stat structure for? couldn't find any information in the programmer's guide...
>

Re: pzxid field in stat structure

Posted by nileader <ni...@gmail.com>.
hi, everyone.
Any one who use https://github.com/sgroschupf/zkclient this.

In zk original api, there is api: zk.addAuthInfo(authentication_type,
correctAuthentication.getBytes());

but in https://github.com/sgroschupf/zkclient, no.

who can tell me why?
or who know the author of the zkclient.