zookeeper-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rakesh Radhakrishnan <rakeshr.apa...@gmail.com>
Subject Re: Asynchronous API's and monotonicity
Date Thu, 05 Jun 2014 16:45:28 GMT
Hi Mudit,

A client will have a consistent order and will dispatches the request
sequentially. Basically its in FIFO order, all requests from a given client
are executed in the order that they were sent by the client. In your case,
Z1 request will be processed first and then Z2 request. Ofcourse, Z1's
sequential number will be less than Z2's sequential number.

But this behaviour may not be same if we perform operations through
different clients. Here network delays or other factors may cause different
clients to see a change.


On Thu, Jun 5, 2014 at 9:02 PM, Mudit Verma <mudit.f2004912@gmail.com>

> Hi Zookeeper Users,
> Lately, I have been working on a research project where I want to use
> zookeeper as a distributed logging service.
> I want to build a queue on top of zookeeper (also provided in recipes).
> What for:
> Intention is to insert some operations performed by different clients in a
> distributed queue, and process them lazily at some later point of time.
>  And I want some ordering between these operations.
> Setup:
> 5 physical  zookeeper servers
> The problem is:
> In my current setup, I am observing a latency of about 13 ms per enqueue
> operation (using synchronous create APIs with sequential flags). I want to
> significantly reduce this time. The other way could be to use asynchronous
> zookeeper calls  but I am not sure what can be the side effects. Would it
> still be monotonous when used with SEQUENTIAL flag?
> For example, a  client X created a SEQUENTIAL node Z1 at time t1 using
> async create, same client created another SEQUENTIAL node Z2 at time t2
> where t2 > t1. Would the monotonic number associated with Z1 be lesser than
> that of Z2?
> Your help is much appreciated.
> Thanks
> Mudit

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message