Can I set replica_factor
as any number in CREATE SPACE statements?
Is it better to set this parameter higher the more machines we use for storage?
The NebulaGraph documentation describes this parameter as follows: Specifies the number of replicas开发者_运维问答 in the cluster. The suggested number is 3 in a production environment and 1 in a test environment. The replica number must be an odd number for the need of quorum-based voting. The default value is 1.
But I don't understand why.
Under the hood, the replication was done via raft, that's the reason why replica factor cannot be even.
Normally, either 1 or 3 is the value you would like to give for 99% of cases, where 1 comes without HA and 3 can suffer from single-point failure.
See more from here
精彩评论