Hydra ETL
Build your first job
Get startedHydra CLILesson 10
Lesson 10 of 11 · Run a workflow

Run the workflow and follow every state

Execute the validated two-step DAG, follow each terminal state, and reconcile the final workflow result with the job output.

hdrctl workflow runabout 9 minutesworkflow validated

1. Objective

Goal

Run hdrctl workflow run workflow.yaml. Read the workflow start, the terminal status of run_first_job, the terminal status of record_completion, and the final 2/2 result.

Course project

Keep working from the cli-course folder. The job is named first-job, and the workflow lessons add workflow.yaml beside it; every command and terminal excerpt in this lesson was run against that same cumulative project.

Reading a result. Durations and process identifiers vary between machines — ignore them. What proves a run is the stable evidence: named files, resolved identifiers, row counters, step states, HTTP status. If one of those differs from the lesson, fix the previous step before continuing.

Prerequisites

  • Lesson 9 completed and checked.
  • The validated first-job CSV project.
  • A terminal opened in the cli-course folder.

2. Steps

01Revalidate immediately before execution

Objective

Use the validated manifest as the exact input to the run.

Actions

  1. Run the workflow validator once more after any edit.
  2. Proceed only when it returns the clean verdict.
hdrctl workflow validate workflow.yaml
What you should see

The same file that will run passes model and graph validation.

✅ Workflow valid — no errors detected.

02Run the workflow

Objective

Execute the job step and its dependent completion action.

Actions

  1. Invoke hdrctl workflow run with the manifest path.
  2. Wait until both step lines and the final summary appear.
hdrctl workflow run workflow.yaml
What you should see

Both real steps reach OK and Hydra reports the observed total.

Workflow  first-job-workflow
────────────────────────────────────────────────────────

✓  Step 'run_first_job' OK (1.5s)
✓  Step 'record_completion' OK (0.0s)

✅ Workflow 'first-job-workflow' completed in 1.5s — 2/2 steps OK

03Read dependency order

Objective

Confirm the output order matches the graph declared in lesson 9.

Actions

  1. Locate run_first_job in the terminal output.
  2. Confirm record_completion follows it.
  3. Match that ordering to depends_on.
Get-Content workflow.yaml
What you should see

The second step's dependency explains why its terminal state appears after the job.

depends_on: []
...
depends_on: ["run_first_job"]

04Verify the data artifact

Objective

Connect the successful job step to its configured default output.

Actions

  1. Open first-job/data/output.csv.
  2. Confirm the workflow-run job produced the same two filtered records.
Get-Content first-job\data\output.csv
What you should see

The orchestrated job preserves the cumulative pipeline result.

id,name,value
1,Alice,100.0
2,Bob,200.0

3. Checklist

VerificationExpected result
Workflow namefirst-job-workflow
Job staterun_first_job is OK
Action staterecord_completion is OK
Final summary2/2 steps OK

4. Troubleshooting

SymptomCauseFix
The workflow file is not foundThe terminal is outside cli-courseChange to the course folder or pass an explicit file path
The job step cannot find its directoryThe relative job path changedKeep workflow.yaml beside first-job
The action does not runIts dependency did not succeedInspect the job step result first, then rerun after fixing the job

5. Next lesson

The CLI now creates, validates, tests, runs, parameterizes, inventories, and orchestrates the same project. The final lesson serves Hydra's FastAPI backend over that workspace and verifies the health endpoint.

Close by

0 / 0 on this page