The protocol that zk uses, zab, relies on TCP to guarantee ordered delivery of messages. Without this transport-level guarantee we'd have to do more work to ensure correctness. It's a nice simplifying element of the protocol. You can read the original papers or various parts of the documentation and wiki such as https://cwiki.apache.org/confluence/display/ZOOKEEPER/Zab1.0
Best C On Dec 25, 2014 6:51 PM, "Ibrahim" <[email protected]> wrote: > Yes you are right when you say "Reliable UDP isn’t a defined standard". > However, there are some protocols has implemented using UDP. For example, > some Red Hat apps, protocols, and framework implemented using reliable UDP > (their own reliable UDP), and they works fast and reliable. > > To answer your question, "what sort of improvements would you expect from > it, over TCP?" > > Zookeeper uses TCP protocol to send/receive messages. For example, when the > leader sends proposal to 4 followers, it sends it one by one, meaning that > it needs to send 4 messages (four outgoing packets). Whereas, to achieve > same thing using RUDP (IP multicast), here leader only needs to send one > messages (one outgoing packets), as a result, it reduces the network > traffic. > > Thank you > > Ibrahim > > > > > -- > View this message in context: > http://zookeeper-user.578899.n2.nabble.com/Why-ZK-uses-TCP-instead-of-UPD-IP-multicast-tp7580715p7580717.html > Sent from the zookeeper-user mailing list archive at Nabble.com. >
