Monday, October 31, 2016

Taste of mongo

In our final project since there is no constraints about the choice of database, our group uses MongoDB to manage data. It was my first time using NoSQL database and here are some thoughts about it.

As for the advantages, one of the things I really like about MongoDB is that I do not need to write schema anymore. The flexible data model MongoDB provided makes managing data a lot more easier. Basically I can store any type of data with desired structure. I can also dynamically update the data model with changing requirement without any interruption to old data. Based on my research, MongoDB also provides high performance in terms of throughput and latency. So far the amount of data we managed is not large enough to prove the statement but I am looking forward to it.

On the other hand, as for the disadvantages, not being able to do join query makes me feeling quite uncomfortable. Being used to relational databases, join is the one of the most frequently used method to retrieve data from different models with a single query. In MongoDB, the alternative is the "lookup" operation which I have not get used to. Besides,
MongoDB does not support transactions except certain atomic operations at single document level which may lead to data inconsistency. 

These limitation of NoSQL database may be the reasons why relational databases dominates the market for over 40 years. However, it is great to know that databases are still evolving for better performance.

No comments:

Post a Comment