Sharding Introduction
Sharding is a method for storing data across multiple machines. MongoDB uses sharding to support deployments with very large data sets and high throughput operations.
Purpose of Sharding
Database systems with large data sets and high throughput applications can challenge the capacity of a single server. High query rates can exhaust the CPU capacity of the server. Larger data sets exceed the storage capacity of a single machine. Finally, working set sizes larger than the system’s RAM stress the I/O capacity of disk drives.
To address these issues of scales, database systems have two basic approaches: vertical scaling andsharding.
Vertical scaling adds more CPU and storage resources to increase capacity. Scaling by adding capacity has limitations: high performance systems with large numbers of CPUs and large amount of RAM are disproportionately more expensive than smaller systems. Additionally, cloud-based providers may only allow users to provision smaller instances. As a result there is apractical maximum capability for vertical scaling.
Sharding, or horizontal scaling, by contrast, divides the data set and distributes the data over multiple servers, or shards. Each shard is an independent database, and collectively, the shards make up a single logical database.
Diagram of a large collection with data distributed across 4 shards.
免责声明:
① 本站未注明“稿件来源”的信息均来自网络整理。其文字、图片和音视频稿件的所属权归原作者所有。本站收集整理出于非商业性的教育和科研之目的,并不意味着本站赞同其观点或证实其内容的真实性。仅作为临时的测试数据,供内部测试之用。本站并未授权任何人以任何方式主动获取本站任何信息。
② 本站未注明“稿件来源”的临时测试数据将在测试完成后最终做删除处理。有问题或投稿请发送至: 邮箱/279061341@qq.com QQ/279061341
软考中级精品资料免费领
- 历年真题答案解析
- 备考技巧名师总结
- 高频考点精准押题
- 资料下载
- 历年真题
193.9 KB下载数265
191.63 KB下载数245
143.91 KB下载数1148
183.71 KB下载数642
644.84 KB下载数2756
相关文章
发现更多好内容- Java 是否支持容器编排?全面解析与实践指南(contain java是否支持容器编排)
- Java 如何通过调用方法来输出数据?(java怎么调用方法输出数据)
- uncomtrade数据库支持的格式大全
- Java OGNL 表达式的解析原理究竟是什么?(java ognl表达式的解析原理是什么 )
- Java泛型中的 extends 操作符对性能有哪些影响?(Java泛型extends的性能影响如何)
- 如何掌握 Java 图形化界面设计原则?(java图形化界面设计原则)
- 在 Java 中如何获取栈顶元素?(java怎么获取栈顶元素)
- 软考高级考试可以自己选批次吗?
- Java 中如何获取字符数组中的字符?(java字符数组怎么获取字符)
- 在 Java 中,JLabel 的文本是否能够实现旋转?(java中jlabel的文本能否实现旋转)