Why would using MongoDB in lieu of etcd as a key value store be a good or bad idea? [closed]
I'd like to get general thoughts from the community as to why MongoDB for key/value would OR would not be a suitable replacement for etcd or other purpose-built key/value store system (consol, zookeeper, etc).
Consul, zookeeper, and etcd all focus on delivering reliable durable storage for limited amounts of data even in the context of failure scenarios like lost instances and network partitions. They act as the "source of truth" for critical configuration data that large infrastructures depend on.
Mongo is a completely different beast. It also has some cluster and failover functions but its reliability and durability in the face of problems is significantly less robust.
So, whether it is a good idea depends on your use case, but if one was using one of etcd, consul or zookeeper for their intended purpose, one would never replace them with mongo.
The unparalleled Call Me Maybe series by Kyle Kingsbury gets into the details about the behavior of various database systems in difficult conditions:
https://aphyr.com/tags/Jepsen
All of the above and many others are covered. Highly recommended.