MongoDB如何确保一致性

来源:互联网 发布:小强软件测试 编辑:程序博客网 时间:2024/04/27 09:37

原文地址:https://www.mongodb.com/faq

How does MongoDB ensure consistency?

Back to Table of Contents

MongoDB is consistent by default: reads and writes are issued to the primary member of a replica set. Applications can optionally read from secondary replicas, where data is eventually consistent by default. Reads from secondaries can be useful in scenarios where it is acceptable for data to be slightly out of date, such as some reporting applications. Applications can also read from the closest copy of the data (as measured by ping distance) when latency is more important than consistency.

Learn more in the MongoDB Architecture Guide.

0 0
原创粉丝点击