
Answer-first summary for fast verification
Answer: Use Cloud Pub/Sub to receive votes and use Cloud Dataflow to process votes in real-time. Use BigQuery to store the votes and display partial results.
## Explanation This scenario requires handling a large volume of voting data during a short 3-minute period with the following requirements: 1. **Handle high load**: Cloud Pub/Sub is ideal for ingesting high-volume streaming data 2. **Real-time processing**: Cloud Dataflow provides real-time stream processing capabilities 3. **Display partial results**: BigQuery supports real-time analytics and can display partial results while voting is ongoing 4. **Count votes exactly once**: BigQuery ensures exactly-once processing semantics 5. **Optimize cost**: BigQuery is cost-effective for analytical workloads and only charges for queries run **Why other options are less suitable:** - **B (Bigtable)**: Good for real-time but not optimized for analytical queries and partial result display - **C (Spanner)**: Overkill for this use case and more expensive - **D (Cloud SQL)**: Not designed for high-volume streaming data and real-time analytics - **E (Cloud Storage)**: Not suitable for real-time querying and partial result display - **F (Datastore)**: Not optimized for analytical workloads and real-time result display The combination of Pub/Sub + Dataflow + BigQuery provides the best balance of scalability, real-time capabilities, cost optimization, and exactly-once processing for this voting scenario.
Author: LeetQuiz .
Ultimate access to all questions.
No comments yet.
NO.15 A live TV show asks viewers to cast votes using their mobile phones. The event generates a large volume of data during a 3 minute period. You are in charge of the Voting restructure* and must ensure that the platform can handle the load and halt all votes are processed. You must display partial results write voting is open. After voting doses you need to count the votes exactly once white optimizing cost. What should you do?
A
Use Cloud Pub/Sub to receive votes and use Cloud Dataflow to process votes in real-time. Use BigQuery to store the votes and display partial results.
B
Use Cloud Pub/Sub to receive votes and use Cloud Dataflow to process votes in real-time. Use Cloud Bigtable to store the votes and display partial results.
C
Use Cloud Pub/Sub to receive votes and use Cloud Dataflow to process votes in real-time. Use Cloud Spanner to store the votes and display partial results.
D
Use Cloud Pub/Sub to receive votes and use Cloud Dataflow to process votes in real-time. Use Cloud SQL to store the votes and display partial results.
E
Use Cloud Pub/Sub to receive votes and use Cloud Dataflow to process votes in real-time. Use Cloud Storage to store the votes and display partial results.
F
Use Cloud Pub/Sub to receive votes and use Cloud Dataflow to process votes in real-time. Use Cloud Datastore to store the votes and display partial results.