AIAny
MLOps2026
Icon for item

pg_durable

Runs durable, checkpointed SQL workflows inside PostgreSQL so long-running data and AI pipelines can resume after crashes without external orchestrators. Provides a SQL DSL, in-process background worker, and Postgres-backed state—useful for embeddings, ETL, scheduling, and fan-out jobs when you can install extensions.

Introduction

Most AI and data pipelines stitch together schedulers, queues, workers, and status tables — and then spend more time handling partial failures and restarts than doing useful work. Putting durable execution inside the database flips that trade-off: workflows execute as checkpointed SQL graphs, state lives in the same backup/ACL model as your data, and the runtime resumes from the last checkpoint after crashes.

What Sets It Apart
  • SQL-first durable execution: workflow graphs are authored in SQL using composable operators (e.g., |=>, ~>) so pipeline logic lives next to the rows it touches instead of in external orchestrators. This reduces duplication of state and simplifies auditing.
  • In-process background worker + Postgres state: a background worker hosts the duroxide runtime while duroxide-pg persists instance state in Postgres schemas. That design avoids external queues or Redis for checkpointing and lets you query progress directly from the database.
  • Practical for AI pipelines: explicitly calls out embedding pipelines (chunk → embed → upsert to pgvector), ingest/transform flows, fan-out aggregations, and scheduling tasks — common patterns in model preprocessing, dataset builds, and inference enrichment.
  • Packaging & compatibility: publishes Debian packages for PostgreSQL 17 and 18 and provides dev workflows (codespace, pgrx) — making it practical to test or run where installing extensions is acceptable.
Who It's For and Trade-offs

Great fit if you already keep canonical state in Postgres and want background workflows that: must survive restarts, are auditable in SQL, or can be expressed as a sequence/graph of SQL steps. It removes many external moving parts (cron, workers, queues) and is especially attractive for embedding/ETL pipelines and database-driven automation.

Look elsewhere if you cannot install extensions or require heavy in-memory arbitrary application logic that doesn’t map to SQL (those steps need to be wrapped as SQL-callable functions or HTTP endpoints). The background worker role must be a superuser, so multi-tenant or highly restricted managed environments may require extra operational controls.

Where It Fits

Think of pg_durable as an alternative to glue-layer orchestrators (cron+jobs tables, lightweight workers) and a complement to broader orchestrators (Airflow, Temporal) when you prefer state locality. Use it to reduce latency and complexity for database-centric pipelines; keep a general orchestrator when workflows must tightly coordinate heterogeneous external systems.

Information

  • Websitegithub.com
  • AuthorsMicrosoft
  • Published date2026/02/13

Categories

More Items

GitHub
AI Infra2026

Provides an end-to-end platform to evaluate, observe, protect, and optimize LLM and AI agent deployments. Integrates OpenTelemetry tracing, 50+ evaluation metrics, agent simulations, an OpenAI‑compatible gateway, and guardrails; self‑hostable under Apache 2.0.

GitHub
AI Train2026

Provides a one-command CLI to fine-tune and post-train LLMs, with layer streaming that lets an 8B model be fine-tuned on a 4 GB laptop GPU. Auto-configures quantization, LoRA adapters, batching and evaluation gates, and supports export and serving workflows.

GitHub
AI Infra2023

Curated learning hub that aggregates roadmaps, tutorials, bootcamps, books, projects, and tool recommendations for learning data engineering and production data infrastructure. Focuses on practical applied learning (projects, interview prep, community links) rather than code libraries.