mongodb - Mongo DB write operation in shard setting -
i new mongodb while going through tutorial got question in mind that, in sharded environment during reading operation "mongos" first checks config server details shard has query. during write operation first checks shard has perform write operation?
thanks in advance, kitty
i going answer based on current stable release of mongodb v3.2.
the config servers store cluster's metadata in config database. mongos instances cache data , use route reads and writes shards.
mongodb writes data config servers when metadata changes, such as:
- after chunk migration, or
- after chunk split.
mongodb reads data config server in following cases:
- a new mongos starts first time, or existing mongos restarts.
- after change in cluster metadata, such after chunk migration.
see also: sharded cluster mechanics.
Comments
Post a Comment