Reputation: 871
I have 2 collections in mongodb - one involves only read operations while the other involves both read and write operations. The read operations are more than write (read: 20 per minute, write: 10 per minute)
I have heard that mongodb puts a lock on the whole db and not only collection during a write operation. So is it wiser to put both these collections into separate databases?
mongodb - 2.6
OS - ubuntu 12.04 LTS
Upvotes: 1
Views: 94
Reputation: 27487
I'd put both collections in a single database. You have what would be considered very light read and write volume. While it all depends on the hardware you use, you schema, types of indexes, etc you are a long way away from having to worry about database locks. I have several production databases that run at 1000X that volume with no issues with database locks. As you scale up you can also shard your larger high volume collections to spread the load out across more servers.
http://docs.mongodb.org/manual/sharding/
Upvotes: 2