Launch price: every exam for $29.99 a year, for the first 300 buyers. See the price

CertStreak
Menu

Create a data pipeline by using a notebook, including precedence constraints

A worked example

Single answer

You are creating a production Lakeflow Job from four workspace notebooks: ingest_data, transform_customers, transform_orders and train_model. The job must meet these requirements:

  • The transform tasks must not start until ingest_data completes successfully.
  • The dependencies must allow the two transform tasks to run in parallel to minimise total job duration.
  • train_model must not start until both transform tasks complete successfully.

Which job configuration meets all the requirements?

Choose one answer
Why

Making both transforms depend on ingest_data allows them to run in parallel after ingestion succeeds. Making train_model depend on both transforms ensures that training waits for both to complete successfully. Chaining the transforms would unnecessarily serialize their execution.

  • Not correct: Source Workspace for all tasks; transforms chained after ingest_data in sequence; train_model depends on transform_orders. Chaining one transform after the other forces sequential execution. The dependency between the transforms prevents the required parallelism.
  • Correct: Source Workspace for all tasks; both transforms depend on ingest_data; train_model depends on both transforms. Both transforms wait for ingestion and can then run in parallel. Making train_model depend on both transforms ensures that it waits for both to complete successfully.
  • Not correct: Source Workspace for all tasks; both transforms depend on ingest_data; train_model depends on transform_orders. With a dependency only on transform_orders, train_model could start while transform_customers is still running. It must depend on both transforms to wait for both.
  • Not correct: Source Workspace for all tasks; both transforms have no dependencies; train_model depends on both transforms. Without dependencies on ingest_data, the transforms can start before ingestion finishes. Each transform needs an ingestion dependency to enforce the required order.

Practise this topic until it's automatic.

Ten questions a day, every answer explained, and misses that come back until you beat them.

Start free