You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@zookeeper.apache.org by Vincent Ngan <ng...@gmail.com> on 2019/10/02 08:04:01 UTC
Can I use czxid as unique sequence number?
Hi,
According to the definition of czxid as mentioned in the documentation, can
I assume that the czxid of every node is unique? If this is the case, can I
just use it for purpose of determining the unique sequence number of a node?
Regards,
vngantk
Re: Can I use czxid as unique sequence number?
Posted by Vincent Ngan <ng...@gmail.com>.
Hi,
Thanks a lot!
Regards,
vngantk
On Tue, Oct 29, 2019 at 12:52 AM Andor Molnar <an...@apache.org> wrote:
> Yes, I think you can do that.
> zxid is currently an AtomicLong in the leader which we increment on every
> write request.
>
> Andor
>
>
> > On 2019. Oct 18., at 17:59, Vincent Ngan <ng...@gmail.com> wrote:
> >
> > I want to determine the order of creation of a number of nodes without
> > using ZooKeeper's sequence feature because I do not want the name of the
> > nodes to be appended with a sequence number.
> >
> > Regards,
> > vngantk
> >
> > On Thu, Oct 3, 2019 at 2:37 AM Enrico Olivelli <eo...@gmail.com>
> wrote:
> >
> >> Can you give more details about your usecase?
> >>
> >> Enrico
> >>
> >> Il mer 2 ott 2019, 10:04 Vincent Ngan <ng...@gmail.com> ha
> scritto:
> >>
> >>> Hi,
> >>>
> >>> According to the definition of czxid as mentioned in the documentation,
> >> can
> >>> I assume that the czxid of every node is unique? If this is the case,
> >> can I
> >>> just use it for purpose of determining the unique sequence number of a
> >>> node?
> >>>
> >>> Regards,
> >>> vngantk
> >>>
> >>
>
>
Re: Can I use czxid as unique sequence number?
Posted by Andor Molnar <an...@apache.org>.
Yes, I think you can do that.
zxid is currently an AtomicLong in the leader which we increment on every write request.
Andor
> On 2019. Oct 18., at 17:59, Vincent Ngan <ng...@gmail.com> wrote:
>
> I want to determine the order of creation of a number of nodes without
> using ZooKeeper's sequence feature because I do not want the name of the
> nodes to be appended with a sequence number.
>
> Regards,
> vngantk
>
> On Thu, Oct 3, 2019 at 2:37 AM Enrico Olivelli <eo...@gmail.com> wrote:
>
>> Can you give more details about your usecase?
>>
>> Enrico
>>
>> Il mer 2 ott 2019, 10:04 Vincent Ngan <ng...@gmail.com> ha scritto:
>>
>>> Hi,
>>>
>>> According to the definition of czxid as mentioned in the documentation,
>> can
>>> I assume that the czxid of every node is unique? If this is the case,
>> can I
>>> just use it for purpose of determining the unique sequence number of a
>>> node?
>>>
>>> Regards,
>>> vngantk
>>>
>>
Re: Can I use czxid as unique sequence number?
Posted by Vincent Ngan <ng...@gmail.com>.
I want to determine the order of creation of a number of nodes without
using ZooKeeper's sequence feature because I do not want the name of the
nodes to be appended with a sequence number.
Regards,
vngantk
On Thu, Oct 3, 2019 at 2:37 AM Enrico Olivelli <eo...@gmail.com> wrote:
> Can you give more details about your usecase?
>
> Enrico
>
> Il mer 2 ott 2019, 10:04 Vincent Ngan <ng...@gmail.com> ha scritto:
>
> > Hi,
> >
> > According to the definition of czxid as mentioned in the documentation,
> can
> > I assume that the czxid of every node is unique? If this is the case,
> can I
> > just use it for purpose of determining the unique sequence number of a
> > node?
> >
> > Regards,
> > vngantk
> >
>
Re: Can I use czxid as unique sequence number?
Posted by Enrico Olivelli <eo...@gmail.com>.
Can you give more details about your usecase?
Enrico
Il mer 2 ott 2019, 10:04 Vincent Ngan <ng...@gmail.com> ha scritto:
> Hi,
>
> According to the definition of czxid as mentioned in the documentation, can
> I assume that the czxid of every node is unique? If this is the case, can I
> just use it for purpose of determining the unique sequence number of a
> node?
>
> Regards,
> vngantk
>