Benefits of having a Read-Replica in AWS RDS

You can combine Multi-AZ deployments and read replicas to enjoy the benefits of each. For example, you can configure a source database as Multi-AZ for high availability and create a read replica (in Single-AZ) for read scalability.

With RDS for MySQL and MariaDB, you can also set the read replica as Multi-AZ, allowing you to use the read replica as a DR target. When you promote the read replica to be a standalone database, it will already be Multi-AZ enabled.

There are several benefits of having a Read-Replica in AWS RDS. To name a few:

1) You can reduce the load on your source DB instance by routing read queries from your applications to the read replica. Read replicas allow you to elastically scale out beyond the capacity constraints of a single DB instance for read-heavy database workloads.

2) You can promote a read replica if the source DB instance fails. You can also replicate DB instances across AWS Regions as part of your disaster recovery strategy.

3) When you create a read replica for Amazon RDS for MySQL, MariaDB and PostgreSQL, Amazon RDS sets up a secure communications channel using public key encryption between the source DB instance and the read replica, even when replicating across regions.

Happy learning!

Cheers!
Aman Kharbanda

Differences between Read-Replicas and Multi-AZ in Amazon RDS

Both these features offers a secondary copy of your data, there are differences between the two. A quick insight into the differences –

Multi-AZ Deployments Read Replicas
Synchronous replication – highly durable Asynchronous replication – highly scalable
Only database engine on primary instance is active All read replicas are accessible and can be used for read scaling
Automated backups are taken from standby No backups configured by default
Always span two Availability Zones within a single Region Can be within an Availability Zone, Cross-AZ, or Cross-Region
Database engine version upgrades happen on primary Database engine version upgrade is independent from source instance
Automatic failover to standby when a problem is detected Can be manually promoted to a standalone database instance

Read replicas are available in Amazon RDS for MySQL, MariaDB, and PostgreSQL as well as Amazon Aurora.

Next write-up will contain how do you promote your secondary (Read-Replica) to become a primary/standalone database.

Happy learning!

Cheers!
Aman Kharbanda