Courseiva
DEA-C01Chapter 7 of 18Objective 2.1

Data Pipeline Orchestration with AWS Step Functions and AWS Glue Workflows

How do you safely chain together a dozen separate data jobs — extract, clean, transform, load — without one crashing into another or running on stale data? Orchestration is the invisible stage manager that ensures each job fires in the correct order, handles failures gracefully, and logs every step so you can sleep at night. For the DEA-C01 exam, understanding orchestration with AWS Step Functions and AWS Glue Workflows is critical because it separates an ad-hoc script that breaks at 3 AM from a production-grade data pipeline that your company can trust.

12 min read
Intermediate
Updated Jul 23, 2026
Reviewed by Johnson Ajibi· Senior Network & Security Engineer · MSc IT Security

A simple way to picture Data Pipeline Orchestration with AWS Step Functions and AWS Glue Workflows

The Restaurant Kitchen Brigade Analogy

A professional kitchen's dinner service is a complex, time-sensitive operation. The head chef does not personally chop every vegetable, sear every steak, and plate every dessert. Those tasks are performed by specialist stations: the saucier, the grillardin, the garde manger. The head chef's job is orchestration — deciding the sequence of orders, monitoring which dishes are nearly ready, and ensuring the assemblers plate each dish at the exact moment its components are complete.

AWS Step Functions is that head chef. It defines the recipe as a state machine: first, run the extract job, then, only if successful, run the transform job, then check for errors, and finally run the load job. AWS Glue Workflows is like the head chef's pre-written kitchen schedule for a banquet. It launches multiple Glue ETL jobs in a defined order, waits for them to finish, and handles failures by calling a backup plan. When a finicky diner (data source) changes their order at the last minute, Step Functions adapts on the fly, while Glue Workflows follows a rigid but reliable banquet plan. Without orchestration, the kitchen would be chaos — jobs firing randomly, colliding over data, and serving raw datasets to the database.

How It Actually Works

Let us start with the problem. A modern data pipeline rarely runs a single job. More often, you have five, ten, or fifty steps: extract data from a source like Amazon S3, clean the records, validate the schema, run a transformation, load it into a data warehouse, and then maybe trigger a dashboard refresh. If you run all of those steps at the same time, they will fight for resources and likely fail because the transformation job starts before the extract finishes. If you use simple timed delays, you waste money waiting. What you need is a system that tracks dependencies, runs steps in the correct order, and knows what to do when something fails. That system is orchestration.

AWS offers two main services for orchestrating data pipelines: AWS Step Functions and AWS Glue Workflows. They overlap in purpose but are designed for different scenarios, and the DEA-C01 exam loves to test when you would choose one over the other.

AWS Step Functions is a serverless orchestration service — 'serverless' means you do not need to manage any underlying servers or infrastructure; AWS handles that completely. You define a workflow as a state machine. A state machine is a visual diagram where each 'state' represents a step in your pipeline. States can do things like run an AWS Lambda function (a piece of code that executes without a server), call an API, or wait for a human approval. The transitions between states are governed by rules: if the step succeeds, go to the next state; if it fails, go to an error-handling state. Step Functions is extremely flexible. You can add conditions, loops, parallel branches, and even integrate with over 200 AWS services directly. It is the go-to tool for complex, custom workflows where you need fine-grained control.

AWS Glue Workflows, on the other hand, is a purpose-built tool for orchestrating Glue ETL jobs. ETL stands for Extract, Transform, Load — the process of pulling data from a source, cleaning and converting it, and placing it in a target store. A Glue Workflow is a visual arrangement of Glue jobs, crawlers (which discover and catalogue data), and triggers that fire jobs in sequence or parallel. It is simpler than Step Functions. You do not write custom logic in a state machine; instead, you point and click to build a dependency graph. Glue Workflows also includes built-in job bookmarks that track which data has already been processed, so the pipeline only processes new data. This makes it ideal for standardised ETL pipelines that run on a schedule, like a daily batch job that refreshes a sales report.

Why do these services exist? Before cloud orchestration, data engineers wrote custom scripts called 'directed acyclic graphs' using libraries like Apache Airflow. While powerful, Airflow required you to set up and maintain your own servers, deal with security patches, and manage a database backend. Step Functions and Glue Workflows remove that operational burden — they are managed services, so AWS handles the infrastructure. They also provide built-in logging, monitoring through Amazon CloudWatch, and error handling like retries and fallback states.

So, which one should you use? That is a classic exam question. Choose Step Functions when you need:\ - \ - Complex branching logic with conditions and loops.\ - Integration with many AWS services beyond Glue — for example, invoking a Lambda function to send an email alert, then calling an API Gateway endpoint.\ - Long-running workflows that may involve human approval steps that take days.\ - Custom error handling that varies per step.\

Choose Glue Workflows when:\ - \ - Your pipeline is purely Glue-based — Glue ETL jobs, crawlers, and triggers.\ - You need simple, linear or parallel execution without complex branching.\ - You want to use Glue's job bookmarks to track incremental data processing automatically.\ - Your team prefers a visual drag-and-drop interface over writing code.\

Both services can be triggered on a schedule using Amazon EventBridge Scheduler or by events like a new file landing in S3. And both provide a history of executions, so you can see exactly which step failed and why. The key is to match the tool to the complexity of your pipeline. On the exam, when you see a question about orchestrating a multi-step data pipeline that involves only Glue jobs, lean towards Glue Workflows. When you see a scenario with diverse services, custom logic, or manual approval steps, pick Step Functions.

Decision flow showing when to choose Glue Workflows versus Step Functions and how each orchestrates a data pipeline.

Walk-Through

1

Define the Workflow Requirements

Before using any AWS tool, list every step in your data pipeline: extract source, clean data, validate schema, transform, load target, send notification. Identify dependencies between steps. For example, the transform step cannot start until the clean step finishes. This dependency map directly informs the design of your state machine or Glue Workflow.

2

Choose Between Step Functions and Glue Workflows

If every step uses a Glue resource (job, crawler), choose Glue Workflows for its simplicity and lower cost. If any step uses a non-Glue service (Lambda, SNS, DynamoDB, ECS), or if you need complex branching, human approval, or custom error handling, choose Step Functions. This decision is a hallmark of DEA-C01 exam questions.

3

Create the Orchestration Blueprint

In Step Functions, write the state machine definition using Amazon States Language (ASL) JSON. In Glue Workflows, use the visual console to drag and drop Glue jobs and crawlers. Define the order of execution: which jobs run in sequence, which run in parallel, and what happens on success or failure. In Step Functions, you explicitly set 'Retry' and 'Catch' clauses; in Glue Workflows, you configure retries on each job separately.

4

Configure Triggers and Event Sources

Set up how the workflow starts. In Glue Workflows, use a schedule trigger (e.g., daily at 6 AM), an on-demand trigger, or an event-based trigger (e.g., a job completes). In Step Functions, use Amazon EventBridge to start the state machine on a schedule or in response to an S3 event. This ensures the pipeline runs automatically without human intervention.

5

Implement Monitoring and Error Handling

Enable CloudWatch Logs and metrics on your orchestration. In Step Functions, execution history shows every state transition. In Glue Workflows, the workflow run history displays each job's status. Configure alerts: if a step fails more than a set number of times, send a notification to an SNS topic. This step is critical for production pipelines — the exam expects you to know how to monitor and react to failures.

6

Test and Iterate

Run the workflow with a small dataset to verify the sequence. Use the execution logs to find bottlenecks or errors. In Step Functions, the visual inspector shows exactly which state failed and why. In Glue Workflows, review the job run logs in CloudWatch. Adjust retry policies or add parallel branches until the pipeline runs reliably.

What This Looks Like on the Job

Imagine a mid-sized e-commerce company called ShopSwift. Every morning, they need to refresh their product recommendation engine with data from the previous day's sales, customer reviews, and inventory levels. The data pipeline looks like this: extract sales records from a transactional database using Glue ETL, crawl the raw data with a Glue crawler to update the catalogue, run two parallel Glue jobs — one to calculate customer purchase patterns and another to compute inventory scores — then merge those results, and finally load the combined recommendations into a DynamoDB table that the website reads.

An IT professional — a data engineer at ShopSwift — would use AWS Glue Workflows for this because every step is a Glue job or crawler. They open the AWS Management Console, navigate to Glue, and create a new workflow. They add a trigger that starts the workflow when a scheduled event fires at 6:00 AM. They then add a 'sales extract' crawler node and an 'ETL clean' job node, connecting them so the job runs only after the crawler succeeds. They add parallel branches for the purchase patterns job and inventory scores job, both of which run after the clean job completes. Finally, they add a 'merge and load' job node that runs after both parallel jobs finish. They configure a 'job bookmark' on each ETL job so that only new data from the previous 24 hours is processed — this saves time and money. They also add an alarm via CloudWatch: if the workflow fails more than three times, it sends a text message to the engineer's phone.

Now consider a different project at ShopSwift: a compliance pipeline that must check every data file uploaded by partners for personal identifiable information (PII). This pipeline cannot use simple linear logic. It needs to:\ - \ - Detect the file type (CSV, JSON, or XML) using a Lambda function.\ - Route the file to a different processing path based on type (a condition).\ - Send a notification to the partner if the file is rejected (send email via Amazon Simple Notification Service).\ - Wait for a human compliance officer to manually approve the file if it contains borderline data (a manual approval step).\ - Then archive the file to a different S3 bucket based on the outcome (a choice state).\

This is too complex for Glue Workflows. The engineer chooses AWS Step Functions. They design a state machine in the Step Functions console, starting with a 'Detect File Type' state that calls a Lambda function. They use a 'Choice' state to branch to three different processing states. Each processing state is a Lambda function that checks for PII. If PII is detected with high certainty, the file is rejected and the workflow calls an 'Send Rejection' state using Amazon SNS. If PII is borderline, the workflow enters a 'Manual Approval' state, which pauses and sends a link to a compliance officer's email. The officer clicks 'Approve' or 'Reject' on a web page, and the workflow resumes from that point. This kind of branching, manual intervention, and integration with non-Glue services is exactly why Step Functions exists.

The difference between these two scenarios is the core of what the DEA-C01 exam tests. The engineer uses Glue Workflows for the standardised daily refresh because it is simpler, cheaper, and built for Glue. They use Step Functions for the compliance pipeline because they need flexibility. Both tools log every execution step in Amazon CloudWatch Logs, so if something breaks at 3:00 AM, the engineer can look at the execution history and see exactly where it failed and why.

How DEA-C01 Actually Tests This

The DEA-C01 exam tests your ability to choose between Step Functions and Glue Workflows for a given scenario. You will see questions that describe a pipeline and ask: 'Which AWS service should a data engineer use to orchestrate this workflow?' The traps are subtle. You must remember that Glue Workflows only orchestrates Glue resources — jobs, crawlers, triggers, and the Data Catalogue. Step Functions can orchestrate anything.

Here are the exact concepts and pitfall patterns the exam loves:\ - \ - State machine definitions: You may be asked to interpret a JSON definition of a Step Functions state machine. Pay attention to the 'Type' field — 'Task' (runs a unit of work), 'Choice' (branching), 'Wait' (adds a delay), 'Succeed'/'Fail' (termination states), 'Parallel' (runs branches concurrently), and 'Map' (iterates over a list of items dynamically). The exam expects you to know which state type to use based on the requirement.\ - Error handling: Step Functions has built-in error handling. Be very familiar with 'Retry' (retries the failed state up to a max number of times with backoff) and 'Catch' (redirects to a different state on failure). The exam may present a scenario where a state fails and ask what the 'Retry' policy should be. Remember that Retry repeats the same state; Catch moves to an error-handling state.\ - Parallelism in Glue Workflows: In a Glue Workflow, you can connect multiple jobs to run in parallel after a single trigger. The exam may show a diagram and ask which job will run first. The answer is that all jobs triggered by the same event run in parallel, but the workflow will not proceed to the next stage until all parallel jobs complete.\ - Job bookmarks: Glue Workflows can use job bookmarks to track processed data. The exam may ask: 'What feature of Glue Workflows ensures that only new data is processed?' The answer is job bookmarks. Know that enabling bookmarks on a Glue ETL job causes it to only process data that has changed since the last run.\ - Cost and complexity: You will see questions pitting Step Functions against Glue Workflows. For example: 'A data pipeline uses only Glue jobs and crawlers. Which is the most cost-effective orchestration choice?' Answer: Glue Workflows, because it is simpler and does not incur the per-state-transition costs of Step Functions. Conversely: 'A pipeline requires manual approval and calls multiple AWS services. Which service is best?' Answer: Step Functions.\ - Triggers in Glue Workflows: Glue Workflows use three types of triggers: 'Schedule' (fires at a set time), 'On-demand' (fires manually), and 'Event' (fires when a job in the workflow finishes). The exam may ask about configuring an event-based trigger to start a downstream job after an upstream job succeeds.\ - Integration with other services: Step Functions has two advanced patterns — 'Express Workflows' for high-volume, short-duration tasks (like processing thousands of log entries) and 'Standard Workflows' for long-running tasks (over 5 minutes). Exam questions may differentiate them: Express Workflows run up to 5 minutes and cost less per execution; Standard Workflows can run up to one year.\

A classic exam trap is a question that describes a pipeline with a mix of Glue and non-Glue services, such as S3 events and Lambda functions, and asks for the orchestration solution. The deceptive answer would be 'Glue Workflows', but the correct answer is 'Step Functions' because Glue Workflows cannot directly invoke Lambda functions. Always check which services the pipeline uses. If it uses anything beyond Glue (including Lambda, SNS, SQS, or DynamoDB), Step Functions is the answer.

Key Takeaways

AWS Step Functions is a general-purpose serverless orchestrator that can coordinate any AWS service using state machines with branching, parallel execution, and human approval steps.

AWS Glue Workflows is a purpose-built orchestrator that only coordinates Glue resources: Glue ETL jobs, crawlers, triggers, and the Data Catalogue.

Use Step Functions when a pipeline involves services beyond Glue, requires custom logic, or needs error handling such as retries with exponential backoff.

Use Glue Workflows when a pipeline consists entirely of Glue jobs and crawlers and needs automatic job bookmarks to process only new data.

Step Functions state machines define tasks using state types: Task (run work), Choice (branching), Parallel (concurrent branches), Wait (delay), and Map (iterate over a list).

Glue Workflows use triggers (schedule, on-demand, or event-based) to start jobs and can connect multiple jobs in parallel, but they do not support direct integrations with Lambda or SNS.

Step Functions provides both Standard Workflows (up to 1 year, ideal for long-running pipelines) and Express Workflows (up to 5 minutes, for high-volume short tasks), and the exam tests the appropriate use case for each.

Job bookmarks in Glue Workflows track which data has been processed, enabling incremental processing that saves time and cost.

Easy to Mix Up

These come up on the exam all the time. Here's how to tell them apart.

AWS Step Functions

General-purpose orchestrator; integrates with over 200 AWS services including Lambda, ECS, SNS, and DynamoDB.

Uses Amazon States Language (ASL) JSON to define state machines with conditional logic, parallel branches, and human approval steps.

Costs based on state transitions per execution; can run for up to one year with Standard Workflows.

AWS Glue Workflows

Purpose-built for Glue resources; only orchestrates Glue jobs, crawlers, triggers, and the Data Catalogue.

Uses a visual drag-and-drop interface within the AWS Glue console to define job dependencies and triggers.

Costs based on the Glue jobs and crawlers run; no per-transition cost, making it cheaper for pure Glue pipelines.

Step Functions Standard Workflow

Designed for long-running executions, up to one year.

Provides exactly-once execution semantics, critical for financial data pipelines.

Costs more per execution compared to Express, suitable for low-volume, high-reliability use cases.

Step Functions Express Workflow

Designed for high-volume, short executions, up to 5 minutes.

Provides at-least-once execution, which may result in duplicate processing if not idempotent.

Costs less per execution, ideal for processing thousands of log files or events per second.

Error Handling: Step Functions Retry

Retry repeats the same failed state with a configurable number of attempts and backoff delay.

Used when you want to automatically retry transient errors like network timeouts.

The state machine continues from the same step after a successful retry.

Error Handling: Step Functions Catch

Catch redirects the execution to a different state (e.g., an error-handling state) when a specific error occurs.

Used when the error is non-recoverable or you want to send a notification instead of retrying.

The state machine moves to a new state and does not return to the failed step.

Schedule Trigger in Glue Workflows

Fires the workflow at a specific time or recurring schedule (e.g., every day at 6:00 AM).

Uses a cron expression to define the schedule.

Independent of any data arrival; best for batch processing on a fixed timetable.

Event-Based Trigger in Glue Workflows

Fires the workflow when a specified upstream job completes successfully.

Creates a dependency chain within the workflow: job A finishes, triggering jobs B and C.

Used to build linear or parallel job sequences without manual scheduling.

Watch Out for These

Mistake

AWS Glue Workflows is just a simpler version of Step Functions.

Correct

Glue Workflows is a service specifically for orchestrating Glue resources (jobs, crawlers, triggers, catalogues). Step Functions is a general-purpose orchestrator for any AWS service. They are not interchangeable; you choose based on the services your pipeline uses.

Because Glue Workflows lives inside the AWS Glue console and only integrates with Glue components, beginners assume it can orchestrate any resource. The word 'workflows' sounds generic, but the scope is narrow.

Mistake

If a Glue job fails in a Glue Workflow, the workflow automatically retries it forever.

Correct

A Glue Workflow does not automatically retry failed jobs by default. You must explicitly configure a retry policy on the job itself (up to 3 retries) or use Step Functions if you need sophisticated retry logic with exponential backoff.

Many beginners think AWS services 'just handle' errors. Glue Workflows will stop and report the failure unless you pre-configure retries. This misconception causes candidates to answer 'zero retries' when the exam expects them to identify the default behaviour.

Mistake

Step Functions can only orchestrate Lambda functions.

Correct

Step Functions can orchestrate over 200 AWS services, including Lambda, ECS batch jobs, Glue jobs, DynamoDB, SQS, SNS, and external HTTP APIs via API Gateway. It is a universal orchestrator, not limited to Lambda.

Because the most common tutorial examples use Step Functions with Lambda, beginners develop a tunnel-vision belief. The exam will test integration with services like ECS or Glue, and candidates mistakenly rule out Step Functions.

Mistake

You can run Step Functions workflows from within a Glue Workflow.

Correct

A Glue Workflow cannot directly call a Step Functions state machine. To combine them, you would use Step Functions as the outer orchestrator that calls a Glue job (not the other way around). Alternatively, you can trigger a Step Functions execution from a Glue job using the AWS SDK, but this is an advanced pattern, not a built-in feature of Glue Workflows.

Because both services handle orchestration, beginners assume they nest easily. The exam tests the direction of integration: Step Functions calls Glue; Glue Workflows does not call Step Functions.

Do You Actually Know This?

Reveal each answer, then mark whether you got it right. Score 60%+ to unlock the next chapter.

Frequently Asked Questions

Can I use Glue Workflows to run a Lambda function directly?

No. Glue Workflows can only run Glue jobs, crawlers, and triggers. To invoke a Lambda function, you must use Step Functions, or call the Lambda function from within a Glue job using an AWS SDK call.

What is the difference between Step Functions Standard and Express workflows?

Standard Workflows are designed for long-running processes (up to one year) and guarantee exactly-once execution. Express Workflows are for high-volume, short tasks (under 5 minutes) and provide at-least-once execution. Use Express for event-processing pipelines, Standard for full data pipeline orchestration.

Does a Glue Workflow automatically retry a failed job?

No. You must configure retries on the Glue job itself (max 3 retries) within the job settings. Glue Workflows will report the failure; it does not automatically re-run the job.

Can Step Functions orchestrate a Glue ETL job?

Yes. Step Functions has a direct integration with AWS Glue, including Glue jobs. You can define a Task state that triggers a Glue ETL job and waits for it to complete before proceeding.

What is a job bookmark in Glue Workflows?

A job bookmark is a feature that tracks the last row processed by a Glue ETL job. When enabled, the next time the job runs, it only processes new or changed data. This saves time and cost by avoiding reprocessing the entire dataset.

How do I trigger a Step Functions state machine from an S3 file upload?

Create an S3 Event Notification that sends the file details to an Amazon SQS queue. Then configure an EventBridge rule that reads from the SQS queue and invokes the Step Functions state machine. Alternatively, use S3 Event Notifications directly with Lambda, which then calls Step Functions.

Terms Worth Knowing

Keep going

You've finished Data Pipeline Orchestration with AWS Step Functions and AWS Glue Workflows. Continue through the DEA-C01 study guide to build a complete picture of the exam.

Done with this chapter?