NIUCLOUD是一款SaaS管理后台框架多应用插件+云编译。上千名开发者、服务商正在积极拥抱开发者生态。欢迎开发者们免费入驻。一起助力发展! 广告
### 主从库之间是如何通信的 For explanation purposes, let's imagine that we have a clusterconsisting of 3 nodes. It contains one index called `blogs` which hastwo primary shards. Each primary shard has two replicas. Copies ofthe same shard are never allocated to the same node, so our clusterlooks something like <>. [[img-distrib]].A cluster with three nodes and one indeximage::images/04-01_index.png["A cluster with three nodes and one index"] We can send our requests to any node in the cluster. Every node is fullycapable of serving any request. Every node knows the location of everydocument in the cluster and so can forward requests directly to the requirednode. In the examples below, we will send all of our requests to `Node 1`,which we will refer to as the _requesting node_. TIP: When sending requests, it is good practice to round-robin through all thenodes in the cluster, in order to spread the load.