How to choose a NoSQL Database

How to choose a NoSQL Database

NoSQL has been beautifully explained by Martin Fowler in his book especially the four main types of NoSQL databases.

  1. KeyValue Databases e.g Riak, Redis, Berkeley DB, CouchBase etc.
  2. Document Databases e.g MongoDB, CounchDB, OrientDB etc.
  3. Column Family Databases e.g Cassandra, HBase, Amazon DynamoDB etc.
  4. Graph Databases e.g Neo4J, OrientDB etc.

Note: OrientDB is a multi-model database hence is both a Document and Graph Database. Quite unique in many ways.

One must be well familiar with each type so that one knows "how to choose a NoSQL tech". However, it seems to be more appropriate to point out "How *NOT* to choose a NoSQL store".

  1. Cool Factor: To replace your existing SQL database because it's simply "cool". NoSQL is not a silver bullet. One should not choose a tech just because its in fashion.
  2. Less Data/Scale: You may under utilize the system or put more efforts just to accommodate few hundreds/thousands of records in a NoSQL data store. This may be easily managed in efficiently and cheaply in any SQL Store and modern ORM suites make it very easy to manage it. Everything looks like a nail when you have NoSQL hammer. BigData technology you use is very specific to your use case. Have seen cases where even Elasticsearch has been used like a schema-less data store for a very small amount of data. (Yes, it can be!)
  3. Application Architecture: Your application architecture is more like a on-premise application deployed to cloud and does not use a true blue micro-service/cloud architecture. Neither does it have features like scaling, auto-discovery, load balancing, fault-tolerance etc. In such a case you may not really reap benefits of NoSQL scalability. Also cloud may prove a costly affair you.
  4. Schemaless: When you are not planning to use full advantage of schemaless database. i.e You use NoSQL database just like a SQL store. Where your applications' data model object / ORM objects are tightly coupled with the schema. i.e a schema change breaks your code "everytime". This also requires you to deal with all SQL like processes for database migrations and upgrades when your business logic changes. Although cannot be completely avoided at times there is no reason why your application should break "everytime" you add a new attribute to NoSQL data store.
  5. SQL Interface: You are choosing a NoSQL database just because it provides a familiar SQL or SQL like interface e.g Cassandra.
  6. Consistency: Most NoSQL database are eventually consistent and not ACID but if your system requires strict transactions then you may need to think again.

Although these are just general thoughts and not a strict guideline.

Let me know what your thoughts about choosing a NoSQL datastore.

要查看或添加评论,请登录

Bhavik Shah的更多文章

  • Scaling up with AWS Lambda

    Scaling up with AWS Lambda

    AWS Lambda is a very effective deployment model for various web frameworks like NodeJS Express, Python FastAPI, GoLang…

  • Composable Architectures

    Composable Architectures

    What is CA? Composable architecture is a way of designing software that makes it easy to create reusable components…

  • Go Lang Framework to watch in 2022

    Go Lang Framework to watch in 2022

    Go Lang is becoming quite popular not only because it is easy to learn but also for its performance, concurrency and…

  • Python frameworks to watch in 2022

    Python frameworks to watch in 2022

    There have been many popular python frameworks. Flask and Django being the most popular of the lot.

  • Why Vue is preferable to Angular in 2022?

    Why Vue is preferable to Angular in 2022?

    UI frameworks have come of age. We had used Angular 1.

  • Baking Multi Tenancy in SaaS

    Baking Multi Tenancy in SaaS

    Multi-tenancy is a common requirement in any modern SaaS. The way a B2C SaaS will support it will vary greatly from a…

    1 条评论
  • How to migrate legacy applications to newer architectures

    How to migrate legacy applications to newer architectures

    This is a well known challenge, faced by many organizations atleast once during the software lifecycle. It is faced by…

  • Eazy Kubernetes on Google Cloud

    Eazy Kubernetes on Google Cloud

    Google Cloud makes is super easy to deploy kubernetes clusters. Step 1: Choose to create a cluster Step 2: Provide…

  • Website to App in Minutes!

    Website to App in Minutes!

    Convert website into mobile app! It has been said that an average user spends over 2 hours on mobile phone while 86% of…

    6 条评论
  • Serve Windows from Google Cloud

    Serve Windows from Google Cloud

    Google Cloud Platform has come a long way from AppEngine days when it was more of PaaS platform allowing you to run app…

社区洞察

其他会员也浏览了