When to Redis or MongoDB?

Technology CommunityCategory: MongoDBWhen to Redis or MongoDB?
VietMX Staff asked 3 years ago
  • Use MongoDB if you don’t know yet how you’re going to query your data or what schema to stick with. MongoDB is suited for Hackathons, startups or every time you don’t know how you’ll query the data you inserted. MongoDB does not make any assumptions on your underlying schema. While MongoDB is schemaless and non-relational, this does not mean that there is no schema at all. It simply means that your schema needs to be defined in your app (e.g. using Mongoose). Besides that, MongoDB is great for prototyping or trying things out. Its performance is not that great and can’t be compared to Redis.
  • Use Redis in order to speed up your existing application. It is very uncommon to use Redis as a standalone database system (some people prefer referring to it as a “key-value”-store).