CertLumen

Databricks Data Engineer Professional · Section 1 · 23% of the exam

Create Lakeflow Jobs that use control-flow operators such as If/Else conditions and For Each loops.

One of the objectives of the Databricks Certified Data Engineer Professional exam, in the section “Developing Code for Data Processing using Python and SQL”. Here is what it covers, the points to remember and a question to try.

What it covers

Create, run and automate the same Lakeflow Job from the UI, the Jobs REST API 2.2, the Databricks CLI, the Python SDK and bundles, choose the right trigger, and build control flow with If/else condition tasks, For each loops, task values and run-if rules.

Points to remember

  • Jobs API 2.2: create, update (replaces sent top-level fields, merges tasks by key), reset (replace everything), run-now (saved job), runs/submit (one-time run, not saved, no retries).
  • CLI: databricks jobs create --json @job.json; run-now <JOB_ID> waits up to 20 minutes by default; --no-wait returns immediately.
  • UI path: Jobs & Pipelines > Create > Job; Switch to code version (YAML) shows the job as code; bundles are the recommended production path.
  • Triggers: cron schedule, periodic, file_arrival, table_update (ANY_UPDATED/ALL_UPDATED), continuous; max_concurrent_runs defaults to 1 and queueing is on by default.
  • run-now accepts job_parameters, only (with + for upstream/downstream), idempotency_token, performance_target, pipeline_params.

Try a question

A job has a schedule, email notifications and five tasks. A deployment script must add a sixth task without changing anything else. Which call is appropriate?

  1. Ajobs/update with new_settings containing a tasks array with the new task
  2. Bjobs/reset with new_settings that contains only the definition of the sixth task
  3. Cjobs/runs/submit with the sixth task and the job's name
  4. Djobs/create with the same job name, which merges into the existing job
Show the answer

A. jobs/update replaces only the top-level fields you send, and arrays such as tasks are merged by task_key, so existing tasks, the schedule and notifications stay. jobs/reset replaces every setting with the new definition.

Written for practice in the style of the exam: never a question from the real exam.

In the course

The lesson Lakeflow Jobs: UI, REST API, CLI and Control Flow teaches this objective (about 50 minutes), and 13 practice questions test it. The course has lessons, exam-style questions, timed practice exams and an AI tutor for every objective, and a pass prediction that tells you when you're ready to book.

More in this section

← Previous objective · All 45 objectives · Next objective →