QuestionQ20

Building and implementing CI/CD pipelines, including continuous testing, for application, infrastructure, and machine learning workloads

You are configuring a CI pipeline in Cloud Build. When you test the pipeline, the following cloudbuild.yaml definition results in 5 minutes for each of the foo and bar steps.

Question Image

The foo and bar steps are independent of one another. The baz step requires both the foo and bar steps to complete before it starts. You want to use parallelism to reduce build times. What should you do?

Explanation

Cloud Build steps execute sequentially by default. Setting the later independent step to waitFor: ['-'] makes it start at build start alongside the first step. A subsequent step without waitFor waits for all preceding steps, or it can explicitly list both step IDs, so baz starts only after foo and bar succeed. Configuring the order of build steps

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!