← All updates Databricks Update One-Pager Navy version
databricks Platform · Updated May 27, 2026

Real-time Mode in Spark Declarative Pipelines

Achieve low-latency operational streaming with the new update_flow API.

What it does

The new real-time mode in Spark Declarative Pipelines allows users to achieve end-to-end latency as low as five milliseconds for operational streaming workloads. It utilizes the `@dp.update_flow` decorator, which enables writing to sinks in update output mode, emitting only changed rows. This mode supports stateful aggregations without the need for watermarks, enhancing the efficiency of data processing in real-time applications.

Why it matters

This update significantly improves the performance of real-time data processing, enabling businesses to implement immediate decision-making capabilities such as fraud detection and personalized recommendations. By reducing latency, organizations can enhance user experiences and operational efficiency, ultimately leading to better customer satisfaction and competitive advantage.

Key capabilities
Real-time Processing
Achieve end-to-end latency as low as five milliseconds for streaming workloads.
Stateful Aggregations
Support stateful aggregations without requiring a watermark.
Update Output Mode
Emit only the rows that changed in each batch to optimize data flow.
Flexible Configuration
Customize flows with optional Spark configurations for enhanced performance.
Recommended use cases
Fraud detection in financial transactions.Real-time personalization for e-commerce platforms.Instant decision-making in customer service applications.
Limitations · remember
!Delta table sinks are not supported as targets for update flows.
Architecture
Lakeflow → Spark Declarative Pipelines → Update Flow API → Real-time Mode
Get started
1
Create Sink
Define a sink using the dp.create_sink method.
2
Define Update Flow
Use the @dp.update_flow decorator to create an update flow targeting the defined sink.
3
Configure Spark Settings
Optionally set Spark configurations for real-time processing.
4
Implement Streaming Query
Return a streaming DataFrame from a user-defined query within the update flow function.
5
Run the Flow
Execute the flow to start processing data in real-time.
Key takeaway
The introduction of real-time mode in Spark Declarative Pipelines enables ultra-low latency processing for critical business applications.
2026-05-27-d1d1230f Generated by the Databricks Updates Agent · browse all updates