Reputation: 8885
I'm quite new to NoSql databases, but I'm really lovin' MongoDB with the official c# driver. It's currently the backend to an MVC application I'm writing, and the simplicity AND speed make my life way way easier.
However I've come to that point in the application where I need really great search. I used to use Solr, but have become quite interested in ElasticSearch.
ElasticSearch, as far as I can tell (from a very superficial level), can do everything MongoDB can in terms of being a document database.
So, if I'm already using a NoSql db, and I need great search, is there any point in Mongo? What's the use case?
Is Mongo faster? Easier to use? Is it the BSON datatypes and drivers? Why not use ElasticSearch as my DB?
I'm currently using AppHarbor and lovin' "The Cloud". I hate IT and want to focus on my application only. With that said, the only advantage I see so far is:
Upvotes: 12
Views: 3830
Reputation: 1257
This is a very good question. I have asked myself the same question and came up with the following answer.
My personal opinion is that I wouldn’t use ElasticSearch if you cannot afford to lose data. I could see using ElasticSearch as a primary data store for something requiring real-time analytics, but did not have any long-term data retention requirements. Otherwise, I would suggest using MongoDB and ElasticSearch together. There is a MongoDB River Plugin for ElasticSearch. This makes it pretty easy to update the ElasticSearch index automatically.
Upvotes: 3