Google Professional Cloud Developer Question 172
Select 2Google Cloud PlatformYou are developing a web application for an e-commerce platform. The application needs to store user profiles, including structured data like user IDs, names, and email addresses, as well as unstructured data like user-uploaded images and reviews. Scalability and performance are critical. Which storage solutions should you use to meet these requirements?
- A
Use Cloud SQL to store all structured and unstructured data.
- B
Use Cloud Firestore for structured data and Cloud Storage for unstructured data.
- C
Use Bigtable for structured data and Cloud Storage for unstructured data.
- D
Use Cloud Spanner for structured data and Cloud Storage for unstructured data.
- E
Use Firebase Realtime Database to store both structured and unstructured data.
Show answer and explanation
Correct answers: B, D
Explanation
To handle both structured and unstructured data in a scalable e-commerce application, a combination of technologies is typically required. For structured data like user profiles, Cloud Firestore (NoSQL) or Cloud Spanner (SQL) provide scalability and strong performance. For unstructured data like images and reviews, Cloud Storage is the optimal choice due to its ability to handle large, binary objects and provide high availability. This makes options 2 and 4 the correct answers for this scenario.
- A. Incorrect.
Cloud SQL is primarily designed for structured, relational data and is not optimized for storing or efficiently retrieving large unstructured data like images or reviews.
- B. Correct.
Cloud Firestore is a NoSQL database that works well for storing structured data, and Cloud Storage is an ideal solution for storing and serving unstructured data like user-uploaded images.
- C. Incorrect.
Bigtable is optimized for high-throughput analytical workloads rather than transactional structured data. While it could work for structured data, it is not the best choice in this scenario. Cloud Storage is suitable for unstructured data but is not paired with the optimal structured data solution here.
- D. Correct.
Cloud Spanner is a globally distributed SQL database for structured data and offers strong consistency, making it suitable for storing structured data like user profiles. Cloud Storage complements this by handling unstructured data effectively.
- E. Incorrect.
Firebase Realtime Database is designed for real-time synchronization and is not optimized for handling unstructured data like images or reviews at scale.