The client wanted to understand the performance characteristics of the different types of cloud databases out there and which database is the right one for their use-case.
Given, they were interested to evaluate AWS DynamoDB, AWS RDS etc we put forward the major features and the differences among all.
The goal was to come up with the performance of the given databases for a given use-case.
Benchmarking is one of the best ways to evaluate the performance of a database, providing vital insights that can prove incredibly useful when growing and scaling. There are a wide range of tools that can help with effective and efficient benchmarking.
We used pgbench for benchmarking AWS RDS. pgbench is a program for running benchmark tests on PostgreSQL. It runs the same sequence of SQL commands over and over, possibly in multiple concurrent database sessions, and then calculates the average transaction rate (transactions per second). By default, pgbench tests a scenario that is loosely based on TPC-B, involving five SELECT, UPDATE, and INSERT commands per transaction. However, we wrote our own transaction script files for testing custom scenarios.
We defined the goals before starting the benchmark such as the tps.
The tests ran in a client-server mode with varying capacity of client instances and fixed database server for a given run.
We used a variety of metrics including Host, CloudWatch, Network to get an idea of the saturation levels.
Provide visible insights into the performance characteristics of choosing a database and how the cloud tenancy affects performance as well.
Draw detailed performance stats to evaluate the database for a given load and capacity.
The conclusions helped the client in choosing the database for the specific use case and use the same information for multiple projects internally.