Preparing your design workspace

Loading the problem and your latest saved attempt…

Fault-Tolerant Batch Dataflow Engine

Design distributed batch DAG execution with partition retries, shuffle recovery and committed outputs.

Problem statement

For this exercise, assume users submit batch dataflow DAGs over immutable input snapshots. The engine runs deterministic map/filter and grouped-aggregation stages across workers, reports progress, supports cancellation and publishes one committed final result.

Workers may fail or execute a task more than once; retries must not duplicate final visible output or consume a partial upstream result. Bound the design to one cluster and durable input/output storage. Streaming, an SQL optimizer, arbitrary external side effects and model-training algorithms are out of scope.

This practice exercise is based on an interview-preparation compilation, not an independently dated interview occurrence.

What to build

  1. Accept a versioned batch DAG plus input snapshot references, schedule its dependencies and expose job/stage/partition progress.
  2. Partition work and exchange grouped data across stages, retrying failed or lost tasks without consuming incomplete upstream results.
  3. Publish a single complete final result manifest and support cancellation that stops new work and prevents a cancelled job from newly committing output.

At scaleExercise target

  • Jobs process up to 1 TB through roughly 1,000 input partitions; grouped stages can create skewed shuffle partitions.
  • A cluster has 1,000 workers and up to 20 concurrent jobs, so scheduling must enforce finite memory, disk and task concurrency rather than launching every runnable task.
  • One worker loss must not restart an entire healthy job; the coordinator can restart from durable job state and completed artifact manifests.