talira

Build complex pipelines of batch jobs in Python

open sourceApache-2.0self-hostablefree

Luigi is a Python package from Spotify for building pipelines of long-running batch jobs. Each task declares its dependencies and outputs, and Luigi resolves the dependency graph, runs what's missing, handles failures and shows progress in a web UI served by its central scheduler. Tasks can be Hive queries, Hadoop or Spark jobs, database dumps, machine learning steps or plain Python, and it comes with command-line integration and a Mypy plugin. It leaves triggering to cron and doesn't distribute execution, so it suits batch pipelines of up to a few thousand jobs. It is free under the Apache License 2.0.

Problems it solves

  • chain dozens of batch jobs in Python so each runs only after its inputs exist
  • rerun a failed pipeline and skip the steps that already produced their output
  • see which tasks in a nightly batch pipeline are done, running or failed
  • stitch Hive queries, Spark jobs and Python scripts into one dependency graph
  • a lightweight Python alternative to Airflow for batch dependencies
  • avoid two cron jobs running the same pipeline step at the same time

Features

  • tasks with declared dependencies and outputs
  • dependency resolution and workflow management
  • central scheduler with a visualizer web UI
  • failure handling and retries
  • command-line integration
  • integrations for Hadoop, Hive, Spark and databases
  • TOML-based configuration
  • Mypy plugin

Limitations

  • Doesn't trigger workflows on a schedule: it relies on cron or another scheduler to start runs1
  • Doesn't distribute task execution across workers: worker nodes can get overloaded at thousands of jobs a day1
  • Not built for near real-time or continuously running pipelines: it focuses on batch processing1

Capabilities

Has a command line toolplan not known
Has official SDKsplan not known

Alternatives

The same job

These do what Luigi does.

  1. Apache Airflow A platform to programmatically author, schedule and monitor workflows
  2. Prefect Workflow orchestration for data pipelines and agentic workflows in Python
  3. Dagster AI-native DataOps platform
  4. Flyte Open source durable runtime for AI and data workflows on Kubernetes

Compare Luigi with the top 3