Latest news about Bitcoin and all cryptocurrencies. Your daily crypto news habit.
Here’s how we switched over to Serverless DynamoDB from MySQL in under two weeks.
About three years back, we created a SaaS product or a Software-as-a-Service product, where we had a requirement to process 50 GB of data with over 2 million read/write operations on a daily basis.
In the hindsight, we knew that relational database wasn’t the right choice for this project. Still, we were really reluctant to use NoSQL as we didn’t have NoSQL experts on board. We didn’t really give NoSQL a serious thought (big mistake).
We went ahead with MySQL as our choice of database. The project went live and within days of launch, we started seeing issues like frequent database locks. So as a logical next step, we upgraded our database server to a more powerful hardware on Amazon RDS. That helped a bit. But again, as our user base increased, we started seeing the same issues all over again.
The next option was Replication. So, we upgraded our database to a Multi-AZ environment and also added a couple of Read-replicas. And that kind of helped us to run this project for another couple of weeks before we started seeing the same issues all over again.
We were in serious trouble. Our application was stalling frequently. Page loads often took several many seconds, and our customers were frustrated. And as a natural consequence, we started losing our customers. And now, we were seriously thinking of using NoSQL database (Better late than never, huh?).
We compared different NoSQL databases like MongoDB, Cassandra, and DynamoDB. Both MongoDB and Cassandra required us to provision server infrastructure as well as the software, and also had a steep learning curve. We really had very less time at hand as we were losing customers on a daily basis. So, a serverless NoSQL database like DynamoDB was our best bet.
It hardly took us two weeks to migrate over from MySQL on RDS to serverless DynamoDB. And this included learning DynamoDB from scratch. DynamoDB worked like a charm and it has been three years now and we haven’t had a single database issue.
From then on, for every project of ours, we prefer using DynamoDB over any other database. There is little to no learning curve involved and being a serverless database, there is no infrastructure overhead either. So, if you were to choose a NoSQL database, I would highly recommend using a serverless NoSQL database. And, you will never go, wrong by choosing DynamoDB as your choice for serverless NoSQL database.
If you’re new to DynamoDB, I talk more about this and take you through hand-on labs in my new online course AWS Serverless Microservices Overview with Hands-on (2018). This is a short and concise course as I know you are short on time. In addition to DynamoDB, you will learn how to create completely serverless microservices using AWS Lambda and API Gateway. We’ll use the new Lambda Console with AWS Cloud9-based Code Editor so you dont have to install any software. All you need is your favorite web browser.
AWS Serverless Computing - API & Microservices with Hands On
But you know, I’m not that selfish and there is a free way of doing this: If you don’t have the money, then head over to my YouTube channel and subscribe. You’ll find free preview of this course there. I truly believe there is enough information out there for you to do this for free and learn these skills as a developer if you have enough determination.
If you enjoyed this post and found it useful, please share, comment, and press that 👏 a few times. . .Maybe it will inspire someone to start learning this new stuff!
Subscribe to my YouTube Channel and follow me on Medium if you’re interested in more informative write-ups like these in the future!
Going Serverless with AWS DynamoDB in under Two Weeks was originally published in Hacker Noon on Medium, where people are continuing the conversation by highlighting and responding to this story.
Disclaimer
The views and opinions expressed in this article are solely those of the authors and do not reflect the views of Bitcoin Insider. Every investment and trading move involves risk - this is especially true for cryptocurrencies given their volatility. We strongly advise our readers to conduct their own research when making a decision.