CLOUD-DATABASE-ENGINEER practice question 10 of 25
Your company is using Cloud SQL for MySQL with an internal (private) IP address and wants to replicate some tables into BigQuery in near-real time for analytics and machine learning. You need to ensure that replication is fast and reliable and uses Google-managed services. What should you do?
Full set: 141 questionsThis solution uses two fully-managed Google Cloud services to create a robust, near-real time replication pipeline. Datastream is a serverless Change Data Capture (CDC) service that can connect to the private IP Cloud SQL for MySQL instance and stream data changes to Cloud Storage. A pre-built Dataflow template can then read this change stream from Cloud Storage and efficiently write the updates to the specified BigQuery tables. This architecture is designed for low-latency, reliable data replication and is the recommended Google-managed pattern for this specific use case.
A. Developing a custom service contradicts the requirement to use Google-managed services and introduces unnecessary operational overhead and complexity.
B. Cloud SQL federated queries allow BigQuery to query data directly in Cloud SQL but do not replicate or move the data into BigQuery, which is a key requirement for analytics and ML performance.
C. Database Migration Service (DMS) is designed for migrating and replicating databases to other managed relational databases like Cloud SQL, AlloyDB, or Cloud Spanner, not to a data warehouse like BigQuery.
1. Datastream and Dataflow for BigQuery Replication: Google Cloud Documentation, "Replicate data to BigQuery". This page explicitly describes the recommended pattern: "Datastream uses the BigQuery Change Data Capture (CDC) functionality and Dataflow to replicate data and schema updates from a source database directly into BigQuery."
2. Datastream Overview: Google Cloud Documentation, "Datastream overview". This document identifies Datastream as Google's "serverless change data capture (CDC) and replication service" and lists BigQuery as a primary destination, reinforcing its suitability for this task.
3. Cloud SQL Federated Queries: Google Cloud Documentation, "Query Cloud SQL data". The documentation states, "BigQuery Cloud SQL federation enables BigQuery to query data residing in Cloud SQL in real time, without copying or moving data." This confirms it is for querying, not replication.
4. Database Migration Service Overview: Google Cloud Documentation, "Database Migration Service overview". The "Supported source and destination databases" section lists the valid destinations for DMS, which include Cloud SQL, AlloyDB, and Cloud Spanner, but not BigQuery.
Keep practicing
Take the free CLOUD-DATABASE-ENGINEER practice test
Ten exam-style questions with answers and explanations, plus the exam facts and study guides.
More questions
Other CLOUD-DATABASE-ENGINEER practice questions
- Question 1Your DevOps team is using Terraform to deploy applications and Cloud SQL databases. After…
- Question 2Your company is developing a new global transactional application that must be ACID-compl…
- Question 3You are designing a database strategy for a new web application. You plan to start with a…
- Question 4Your application uses Cloud SQL for MySQL. Your users run reports on data that relies on …
- Question 5You plan to use Database Migration Service to migrate data from a PostgreSQL on-premises …
- Question 6You host an application in Google Cloud. The application is located in a single region an…
