Databricks Adds Rewind Feature to Spark Declarative Pipelines
Databricks announced a rewind feature for Spark Declarative Pipelines that restores both table data and streaming process state to a past point, reducing the need for backfills.
Quick answer
What is the new rewind feature Databricks announced for Spark Declarative Pipelines?
Databricks announced a rewind feature, powered by Spark Declarative Pipelines, that restores a pipeline's table data and the streaming processes producing it to a past point in time together. The company says this removes the need for ad hoc backfills after bad data or bugs affect a pipeline, letting processing resume where it left off.
Key takeaways
- Databricks announced a new rewind feature built on Spark Declarative Pipelines (SDP) that restores both table data and the streaming processes that produced it to a prior point in time.
- The company says existing tools like Delta Lake's time travel and RESTORE only roll back table data, leaving ingestion processes unaware of the rollback and requiring manual backfills to fix.
- Databricks says the feature periodically generates 'rewind points,' which are consistent metadata snapshots across every flow and dataset in a pipeline, that can be selected to roll the whole pipeline back.
- To support this, Databricks extended the Structured Streaming checkpoint layer with a new 'control batch' type and, on Databricks Lakeflow, introduced 'pinning' to retain streaming versions for up to 7 days.
- For Auto Loader, which consumes transient cloud file notifications that cannot be restored, Databricks says it added a 'rewind log' of archived checkpoint metadata to enable replay without major storage cost increases.
Databricks has introduced a rewind feature for Spark Declarative Pipelines (SDP) that lets users roll back an entire data pipeline, both the data stored in tables and the streaming processes that produced it, to a point in the past, according to a company blog post written by engineer Jose Torres.
The problem it addresses
Databricks says bad data commonly enters pipelines through source systems generating faulty rows, subtly buggy transformation logic, or upstream changes landing before downstream aggregation logic is ready to handle them. The company says existing tools, such as Delta Lake's time travel and RESTORE commands, can roll back the state of an individual table, but the streaming processes that wrote to that table are left unaffected and still consider the data already processed. According to Databricks, fixing this today generally requires ad hoc backfills, a task the company says can range from "annoying to outright infeasible" depending on pipeline size.
How rewind works
Databricks says the new feature periodically generates what it calls "rewind points": consistent metadata snapshots covering every flow and dataset in a pipeline's dataflow graph. When an error is discovered, a user can select one of these snapshots and execute a rewind, which the company says brings both table data and the pipeline's operational state, such as watermarks and aggregate buffers, back to that point. Once the rewind completes, Databricks says the pipeline can resume processing, after any necessary fixes to data or logic, without further coordination or backfill work.
Engineering changes behind the feature
According to Databricks, implementing rewind required two main technical additions. First, the company says it built a "cascade" mechanism to compute which version to roll back to for each dataset and flow, including cases where flows with dependencies run in parallel in continuous execution, and added logic so replayed flows skip data ranges already consumed, avoiding duplication.
Second, Databricks says it extended the Structured Streaming checkpoint layer, which already maintains a metadata log of offsets and state for failure recovery, with two new capabilities. The company says it updated the streaming protocol to allow restarting a stream from any prior batch still within retention, introducing a new "control batch" type to represent operations like rewinds, repartitions, or protocol upgrades. On Databricks Lakeflow, the company says it added a "pinning" capability that retains a marked streaming version, along with its metadata logs, source state, and state store state, for up to 7 days even if the normal 100-batch retention window is exceeded.
Auto Loader support
Databricks singles out Auto Loader, which ingests data via transient cloud file notifications, as a case where rewinding cannot simply restore the original source state because those notifications are already consumed and not recoverable. To address this, the company says it added a "rewind log" containing metadata for archived checkpoint files, enabling fast lookup of files with relevant replay information. Databricks says this rewind log also supports on-demand loading of Auto Loader's checkpoint data during normal execution, which the company says helps control disk usage as retention increases.
Source: Databricks Blog, "Incremental rewind with Spark Declarative Pipelines," published December 2, 2026.
Frequently asked questions
- What problem is the rewind feature meant to solve?
- Databricks says data pipelines can produce bad results from bad source data, bugs in transformations, or timing issues with upstream data, and fixing this today typically requires ad hoc corrections and backfills across many affected tables.
- How is rewind different from Delta Lake's existing RESTORE command?
- Databricks says RESTORE only rolls back a table's data, not the processes that wrote to it, so those processes still think the data was already handled; rewind restores both the table state and the streaming flows together.
- What new technical components did Databricks build to support rewind?
- Databricks says it added 'rewind points' as consistent pipeline-wide metadata snapshots, a new 'control batch' type in the Structured Streaming checkpoint layer, a 'pinning' mechanism on Databricks Lakeflow to retain streaming versions up to 7 days, and a 'rewind log' for Auto Loader checkpoint metadata.
- Does rewind eliminate the need for backfills?
- Databricks says rewind minimizes and in many cases avoids the need for backfills entirely by letting the whole pipeline, including operational state, be rolled back and resumed rather than manually reprocessed.