Google Professional Cloud Database Engineer Question 249
Select 4Google Cloud PlatformYour team is managing a Cloud SQL for PostgreSQL instance that handles a high number of read requests. The read traffic is causing performance bottlenecks on the primary instance. You have been tasked with implementing a solution to offload some of the read traffic while ensuring minimal impact on the primary instance's performance. Which of the following considerations are important when assessing the use of read replicas in this scenario?
- A
The number of read replicas supported by the Cloud SQL instance and their impact on replication lag
- B
The location of the read replicas relative to the primary instance to minimize latency
- C
The ability to configure the read replicas to handle write operations in case of failure
- D
The additional cost associated with provisioning and maintaining read replicas
- E
The need to ensure that applications can redirect read queries to the replicas automatically
Show answer and explanation
Correct answers: A, B, D, E
Explanation
Read replicas in Cloud SQL are used to distribute read traffic and reduce the load on the primary instance. Key considerations include the number of replicas supported, replication lag, placement of replicas to reduce latency, cost implications, and ensuring that applications can route read queries to replicas. However, read replicas do not support write operations, even in failure scenarios, as they are intended solely for read scaling.
- A. Correct.
Correct: The number of read replicas supported by Cloud SQL depends on the database engine and tier, and replication lag could impact the consistency of read data.
- B. Correct.
Correct: Placing read replicas in the same region as the primary instance reduces network latency, ensuring faster read performance.
- C. Incorrect.
Incorrect: Read replicas are designed to handle read traffic only and cannot handle write operations directly, even in failure scenarios.
- D. Correct.
Correct: Each read replica incurs additional costs, so it is important to consider cost implications when assessing the use of replicas.
- E. Correct.
Correct: Applications need to be configured to direct read queries to replicas, which may require changes in connection configurations or application logic.