Orchestration & Workflow Design Flashcards

(38 cards)

1
Q

What is orchestration in data engineering?

A

Coordinating the execution order, dependencies, scheduling, and error handling of multiple data processing tasks and pipelines.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

How does orchestration differ from simple job scheduling?

A

Scheduling runs jobs at specific times, while orchestration manages dependencies, conditional logic, retries, and end-to-end workflows.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is a DAG (Directed Acyclic Graph) in workflow tools?

A

A graph where nodes are tasks and edges represent dependencies, with no cycles, defining a valid execution order.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Why are DAGs used to represent data pipelines?

A

They clearly encode dependencies and prevent circular flows, allowing the orchestrator to determine safe parallel execution and retries.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is a task in the context of orchestration?

A

A unit of work, such as a script invocation, SQL query, or API call, that the orchestrator can schedule and monitor.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is a dependency between tasks?

A

A rule that one task must complete successfully before another can start, enforcing correct ordering of steps.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is the difference between schedule-based and event-based triggering?

A

Schedule-based triggering runs tasks at defined times, while event-based triggering runs tasks when specific events occur, such as file arrivals or upstream completions.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Why are retries important in orchestrated pipelines?

A

Transient failures such as network issues or temporary service unavailability can be resolved by rerunning tasks without manual intervention.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is exponential backoff for retries?

A

A retry strategy that increases the delay between retries after each failure, reducing pressure on failing systems.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is a backfill in the context of orchestration?

A

Running a pipeline over historical date ranges to populate or repair data for past periods.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Why must backfills be handled carefully?

A

They can generate heavy load, interfere with regular runs, and require idempotent logic to avoid duplicating data.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is a workflow’s SLA (Service Level Agreement)?

A

An agreed target for freshness or completion time, such as having daily data ready by 7 AM each morning.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Why are SLAs important for orchestration design?

A

They influence scheduling, resource allocation, alerting, and prioritization of jobs to meet business deadlines.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What is the critical path in a DAG?

A

The longest sequence of dependent tasks that determines the minimum possible completion time of the workflow.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Why is identifying the critical path useful?

A

Optimizing tasks on the critical path gives the biggest impact on end-to-end latency and SLA adherence.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is a sensor task or dependency check?

A

A task that waits for a condition to be met, such as file presence or upstream system completion, before allowing downstream tasks to run.

17
Q

What is a failure handler or on-failure hook?

A

Logic that runs when a task or workflow fails, such as sending alerts, triggering compensating actions, or creating tickets.

18
Q

Why is idempotency critical for orchestrated tasks?

A

Because orchestration systems may rerun tasks after failures or backfills; idempotent tasks ensure repeated runs do not corrupt data.

19
Q

What metadata should be logged for each workflow run?

A

Start and end times, status, parameters, input ranges, row counts, errors, and upstream/downstream relationships.

20
Q

Why is parameterization important in workflows?

A

It allows the same DAG and code to run for different dates, environments, or customers without duplicating logic.

21
Q

What is environment separation in orchestration (dev/test/prod)?

A

Running pipelines in distinct environments or accounts to test changes safely before they affect production data.

22
Q

Why should deployments of orchestration code be version-controlled?

A

Version control enables rollback, code review, and clear tracking of which version introduced a change or incident.

23
Q

What is a blue/green or canary deployment in pipeline changes?

A

Deploying new versions alongside existing ones, routing a subset of traffic or data to them before full cutover, to reduce risk.

24
Q

What is dependency inversion at the orchestration level?

A

Designing pipelines so they depend on stable interfaces or contracts between stages rather than hardcoded details of internal implementations.

25
Why is it useful to break large workflows into smaller sub-DAGs or modular pipelines?
Smaller workflows are easier to understand, test, reuse, and operate, and can be composed into larger end-to-end processes.
26
What is a common anti-pattern in orchestration design?
Placing too much logic directly in the orchestrator (e.g., large scripts or SQL embedded inline) instead of calling tested, versioned code modules.
27
Why should the orchestrator be treated as a coordinator, not a compute engine?
Orchestrators should trigger external compute (warehouses, Spark jobs) and manage states rather than doing heavy data processing themselves.
28
What is a cron expression used for?
Defining complex schedules for periodic task execution, such as 'every weekday at 2 AM'.
29
Why must timezone considerations be explicit in scheduling?
Daylight savings and region differences can cause jobs to run at unexpected times if timezones are not clearly defined.
30
What is monitoring in orchestration?
Tracking the status, duration, and failures of tasks and workflows over time to detect anomalies and performance issues.
31
What is alerting in orchestration?
Notifying humans or systems when workflows violate SLAs, fail, or exhibit abnormal behavior, so issues can be investigated promptly.
32
Why is it useful to have success notifications in some cases?
They confirm that critical workflows completed as expected and can be used to trigger downstream processes or communication.
33
What is the role of tagging or labeling workflows and tasks?
Tags help group and filter workflows by team, domain, environment, or priority for reporting and management.
34
Why should orchestrated workflows be tested with realistic data and scenarios?
To ensure that dependencies, error handling, and performance behave correctly under real-world conditions, not just toy examples.
35
What is the difference between orchestration and choreography in distributed systems?
Orchestration uses a central controller to manage interactions, while choreography relies on decentralized components reacting to events and contracts.
36
When might an event-driven, choreographed architecture be preferable?
When systems need to be loosely coupled, independently deployable, and responsive to events without a central orchestrator.
37
Why do many organizations use both orchestration and choreography?
Orchestration suits complex, tightly controlled workflows; choreography suits scalable, decentralized integrations; both patterns often coexist.
38
What is a good one-sentence mental model for orchestration in data engineering?
Use a central, versioned DAG to coordinate small, idempotent tasks that move and transform data in a predictable, observable, and SLA-respecting way.