Author: Liu Xuhui Raymond reprinted. Please indicate the source
Email: colorant at 163.com
Blog: http://blog.csdn.net/colorant/
More paper Reading Note http://blog.csdn.net/colorant/article/details/8256145
Keywords
Chubby, paxos,
Distributed Lock Service
=
Target question =
Provides a coarse-grained lock service for distributed systems and small-capacity file storage services.
=
Core Idea =
The paxos logic solution is provided in the form of services rather than libraries. The small-capacity file storage service is provided to store decision-making results and other auxiliary information to meet the system's distribution and notification requirements.
The lock is not mandatory. The client must follow the rules for obtaining the lock to operate data.
A chubby service is typically composed of five nodes.
Lease is used to elect and maintain a master node. All client read and write operations are directed to the master node. The master node synchronizes the data of the copy node through the paxos process.
To support a large number of client connections at a lower cost. The system provides an event notification mechanism to reduce the client's polling needs. However, there are still many applications that require polling. Therefore, the cache mechanism is further used to cache results on the client.
Event Notifications include file content modification, addition and deletion of sub-nodes (such as the discovery of new services), chubby master failure, and file handle failure.
The client maintains a session on the server that relies on keepalive information updates and updates the cache through the delivery of keepalive messages.
=
Related Research, project, etc. =
Paxos
Theoretical Basis of Synchronization
Zookeeper
Provides similar file API interfaces and Client Cache mechanisms for Distributed System collaboration, but does not provide the lock service, the client uses its own specific rules to implement the lock service through the support of transient files.
=
Others =
The original design was to provide the Distributed Lock service, but in Google, due to file storage, client cache and other mechanisms, it was widely used as nameservice.
(DNS Service)