DEV Community

Hasura for Hasura

Posted on • Originally published at hasura.io on

Comparison of Managed PostgreSQL Providers: AWS RDS vs Google Cloud SQL vs Azure PostgreSQL

Comparison of Managed PostgreSQL Providers: AWS RDS vs Google Cloud SQL vs Azure PostgreSQL
Comparison of Managed PostgreSQL Providers

Hey there! My name is Gunar. I’m a Software Development consultant from London. I’ve been a happy user of Hasura for many years now and I was happy to collaborate with Hasura for this blog post. We’ll be talking about managed Postgres cloud providers.

Hasura gives us instant realtime GraphQL & REST APIs on new and existing Postgres databases. While building a new application with Hasura, I have often had to go through the choices of which managed cloud provider to pick. This is a post that is meant to ease that decision making process where I compare some of the popular providers based on the vectors I have used for my clients.

That is, service providers that perform all maintenance tasks for us. These services allow us to have a reliable database on the cloud, without having to worry about applying updates, managing servers, and keeping a big infra team just to maintain our database layer.

We’re going to be looking at six cloud providers:

  • AWS
  • GCloud
  • Azure
  • DigitalOcean
  • Heroku
  • ElephantSQL

Table of Contents

Thought I’d start off with the comparison table right off the bat. And let you get a general overview before diving into the deets. As one might’ve expected, AWS is setting the bar, with GCloud and Azure tied for a close second. Then we have slightly simpler solutions like DigitalOcean, Heroku, and ElephantSQL—not too far behind either!

Databases are complex, multi-faceted creatures so we'll be looking at multiple characteristics. Which are auto-scaling, monitoring and metrics, costs, versions, extensions, backups, high availability, and security. If you really want to get a good picture of these services, I’d recommend diving in and reading each section.

I couldn't comment on the price as different providers offer different benefits. However, the costs section will give us an idea of how much a single server database might set us back with each of these providers.

Generally speaking:

  • If you’re an indie hacker or small startup , a simpler solution like DigitalOcean, Heroku, or ElephantSQL might be a good fit. These providers have simpler cost structures and their offerings come in pre-defined packages.
  • If you’re an enterprise company , you’ll want the stability and guarantees of big players such as AWS, GCloud, and Azure.

Might be good to remind you that Hasura and Hasura Cloud work with all providers.

AWS GCloud Azure DigitalOcean Heroku ElephantSQL
Auto-scaling
Monitoring and Metrics ⏺️
Costs 🤷 🤷 🤷 🤷 🤷 🤷
Versions ⏺️ ⏺️
Extensions
Backups
High Availability ⏺️
Security ⏺️

High Availability

High Availability speaks to data redundancy, availability, and reliability. All providers offer this capability, through read-only followers and automatic failover.

As you can see below, most providers make the transition in the background so that you don’t have to tell the application layer to point to a new Postgres URL. All but Heroku. Heroku will update the environment variable DATABASE_URL for your Dynos automatically (which triggers a restart) but this obviously won’t work if you have services hosted on non-Heroku servers.

Also, quick shout out to the Azure team. They’ve taken High Availability one step further in simplifying and hiding the complexity away. For example, even the Single Server plan, in fact, stores “three copies of data within a region to ensure data redundancy, availability, and reliability.” So you get High Availability for the price of a single server and that’s pretty cool.

Static IP/endpoint Automatic failover
AWS [](https://aws.amazon.com/rds/ha/) [](https://aws.amazon.com/rds/ha/)
GCloud [](https://cloud.google.com/sql/docs/postgres/high-availability) [](https://cloud.google.com/sql/docs/postgres/high-availability)
Azure [](https://docs.microsoft.com/en-us/azure/postgresql/concepts-high-availability) [](https://docs.microsoft.com/en-us/azure/postgresql/concepts-high-availability)
DigitalOcean [](https://docs.digitalocean.com/products/databases/postgresql/) [](https://docs.digitalocean.com/products/databases/postgresql/)
Heroku [](https://devcenter.heroku.com/articles/heroku-postgres-ha) [](https://devcenter.heroku.com/articles/heroku-postgres-ha)
ElephantSQL [](https://www.elephantsql.com/blog/high-availability-HA-PostgreSQL-plans-at-ElephantSQL.html) [](https://www.elephantsql.com/blog/high-availability-HA-PostgreSQL-plans-at-ElephantSQL.html)

Auto-scaling

Auto-scaling is a relatively new capability of managed databases. Currently AWS and Azure support auto-scaling of both the storage and server. Interestingly, Google Cloud doesn't support auto-scaling for Postgres yet.

  • Auto-scaling storage means the provider will automatically provision more disk space as required by the database.
  • Auto-scaling servers means the provider will automatically scale up the database, either vertically or horizontally. The most common operation is spinning up more read-only replicas, but beefing up the primary instance is possible too.

Auto-scaling is opt-in but make sure it's properly configured. Automatically-scaling capacity also automatically scales costs ;)

Head to https://hasura.io/blog/comparison-of-managed-postgresql-aws-rds-google-cloud-sql-azure-postgresql/ for the rest of the article!

Top comments (0)