Hi Prabhjot,

See some comments inlined:

> On 30 Aug 2015, at 16:47, Prabhjot Bharaj <[email protected]> wrote:
> 
> Hello Folks,
> 
> I am going through zookeeper internals described here:
> http://zookeeper.apache.org/doc/r3.4.6/zookeeperInternals.html
> 
> I have some very basic doubts in understanding the Gurantees - *Reliable
> delivery, **Total order *and *Causal order*
> 

Yeah, that discussion is a bit outdated, I haven't at it in a while and I cans 
ee that it can certainly be improved. This is referring to the guarantees of 
the delivery of state updates for the internal replication protocol. 

> 1. I do not understand the term - 'delivery' and 'order' in these sections.
>   a) Delivery - Does 'delivery' refer to delivery of messages from server
> to server or server to client ?

Delivery is referring to the replication protocol of the servers, so the 
delivery refers to servers delivering state updates. A simple way of thinking 
about this is the following. The zookeeper servers implement an application, 
which is a data tree of znodes. The servers rely on a replication protocol to 
guarantee that the state of the data tree across nodes is consistent, but they 
implement the replication protocol themselves. For abstraction purposes, the 
protocol takes proposals (of state updates) and delivers the update once there 
is agreement.   

>   b) Order - As per this link:
> https://cwiki.apache.org/confluence/display/ZOOKEEPER/Zab+vs.+Paxos, state
> updates must be ordered - What kind of state updates are these ? Does the
> term - 'order' in this link and the one shared in the top of this email
> have the same meaning ?

State updates are updates to the zookeeper data tree. Order here refers to the 
order in which the state updates are delivered to the data tree in a server. 

> 2. *'**If a message, m, is delivered by one server, it will be eventually
> delivered by all servers.'* - delivered <from what> <to what> ?
> 

This is again about the replication protocol. If you think of the broadcast 
primitive the replication of zookeeper relies upon as a black box, then you 
have roughly two calls: propose and deliver. A propose call takes a state 
update while a deliver call is an upcall that is invoked when the ensemble has 
agreed that the state update is ready to be delivered (to the data tree 
application). Only the leader is allowed to propose.

> 3. If a and b are delivered messages, either a will be delivered before b
> or b will be delivered before a -- dont really understand what this means !
> 

Messages a and b refer to messages.

> 4. the terms sender - Does sender classify as one of the zookeeper servers
> in the cluster or the client ?
> 
> 

Sender in this context is a zookeeper server.

> Request you to share your knowledge on my doubts so I can learn more on the
> internals and be able to use zookeeper effectively
> 

You probably don't need to understand the internals to use it effectively, but 
learning is surely fine if that's what you want to do.

-Flavio

Reply via email to