BigData-Apache ZooKeeper

 

2017-09-29 23:34:45

Apache core project : ZooKeeper

Unlike a typical file system, which is designed for storage, ZooKeeper data is kept in-memory, which means ZooKeeper can archive highput and low latency numbers;

ZooKeeper is a high-performance cooridination service for distributed applications.

it exposes common services - such as naming, configuration management, synchronization, and group service - in a simple interface so you don`t have to write them from scratch.

You can use it off-the-shelf to implementa consensus, group management, leader election, and presence protocols, And you can build on it for your own, specific needs.

 

 

 

The servers that make up the zookeeper service must all know about each other. They maintain an in-memory

image of state. along with a transaction logs and snapshots in a persistent store.

As long as a majority of the servers are available, the ZooKeeper service will be availiable.

Client connect to a single ZooKeeper server. The client maintains a TCP connection through which it sends requests, gets response, gets watch events, and sends heart beat. if the TCP  connection to the server breaks, the client will connect to a different server.

 

ZooKeeper Is Ordered.

ZooKeeper stamps each update with a number that reflects the order of all ZooKeeper transactions. Subsequent operations can use the order to implement higer-level abstractions, such as synchronization primitives.

 

ZooKeeper Is fast.

It is especially fast in "read-dominat" workloads. ZooKeeper applications run on thousands of machines, and it performs best where reads are more common than writes, at ratios of around  10 : 1

 

Data model and the hierchical namespace

 

API

 

Implementation

 

shows the high-level components of the ZooKeeper service. With the exception of the request processor,

each of the servers that make up the ZooKeeper service replicates its own copy of the components.

 

 1 the replicated database is an in-memory database containing the entire data tree.

 2 updates are logged to disk for recoverability, and writes are serialized to disk before thet are applied to the in-memory database.

 

转载于:https://www.cnblogs.com/masterSoul/p/7613223.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值