producer library linked to all kinds of services which generate logs
broker processes
consumer library linked to consumer application
zookeeper hold global information
Message是有key的,map到topic的一个partition,进而定位到broker,一个broker上维护什么topic的哪个partition的信息存在zookeeper上,
consumer 订阅topic的一个partition,通过zookeeper找到broker,pull message,
broker 把一个partition看成一个逻辑log文件,分成一个个 segment File。producer push来的消息append到最后,message Id 就是 在partition里的位移。consumer自己维护下一次读的offset,保存在zookeeper。
0.8版本之前partition没有replica,后来支持了,一个partition leader负责读写
http://www.ixdba.net/archives/2014/04/314.htm
http://blog.csdn.net/colorant/article/details/12081909
http://my.oschina.net/frankwu/blog/303745