
Answer-first summary for fast verification
Answer: Stop the Cloud Dataflow pipeline with the Drain option. Create a new Cloud Dataflow job with the updated code
The correct approach is to stop the Cloud Dataflow pipeline using the 'Drain' option and then create a new job with the updated code. This method ensures that all current data is processed before stopping, preventing any data loss. The 'Drain' option allows the pipeline to complete processing of existing data, making it the safest choice for updates. Other methods, such as using the 'Cancel' option or attempting in-flight updates with new or existing job names, risk data loss by not ensuring all data is processed before changes are applied.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
No comments yet.
You're overseeing a streaming Cloud Dataflow pipeline and your team has introduced a new version featuring an updated windowing algorithm and triggering strategy. What's the best method to upgrade the current pipeline to this new version without any data loss?
A
Stop the Cloud Dataflow pipeline with the Cancel option. Create a new Cloud Dataflow job with the updated code
B
Update the Cloud Dataflow pipeline inflight by passing the --update option with the --jobName set to a new unique job name
C
Update the Cloud Dataflow pipeline inflight by passing the --update option with the --jobName set to the existing job name
D
Stop the Cloud Dataflow pipeline with the Drain option. Create a new Cloud Dataflow job with the updated code