What is Lambda Architecture?
Lambda architecture is a design pattern for big data processing that combines real-time streaming (speed layer) with batch processing (batch layer). It aims to provide both low-latency responses and historical analytics. The architecture consists of three layers: the speed layer, the batch layer, and the serving layer.
The speed layer handles real-time data streams using a distributed database system like Apache Storm or Kafka Streams. The batch layer processes historical data through batch jobs executed periodically by systems such as Apache Hadoop or Spark. The serving layer provides a single view of the data to end-users.
Reconciliation Process
In Lambda architecture, the reconciliation process ensures that the real-time and batch processing layers produce consistent results. This is achieved by periodically recomputing the batch layer's output based on the latest data from the speed layer. The reconciled serving estimate combines these two outputs to provide a unified view of the data.
The strip chart in this simulation visualizes the reconciliation process over time, showing how the real-time and batch estimates converge towards the ground truth.
Key Components
The speed layer is responsible for processing incoming data streams quickly. It uses a distributed database to store and query this data in near real-time. The batch layer processes historical data through batch jobs, which are executed periodically with configurable intervals.
The serving layer aggregates the outputs from both layers into a single view that can be queried by end-users or applications.
Interactive Controls
By adjusting the event-rate slider, you can simulate different levels of data throughput. The batch-interval slider controls how often the batch layer recomputes its output based on the latest speed layer data. The speed-layer-noise slider introduces variability in the real-time data stream to demonstrate the impact of noise on the reconciliation process.
The Lambda/Kappa toggle allows you to switch between different formulas that drive the batch layer's recompute jumps, illustrating how these changes affect the overall performance and accuracy of the system.
Frequently asked questions
What is the purpose of the reconciliation process in Lambda architecture?
The reconciliation process ensures consistency between real-time and batch processing layers by periodically recomputing the batch layer's output based on the latest data from the speed layer, providing a unified view of the data.
How does adjusting the event-rate slider affect the simulation?
Adjusting the event-rate slider changes the amount of incoming data in real-time, demonstrating how varying loads impact the performance and accuracy of both the speed and batch layers.
Why is it important to periodically recompute the batch layer's output?
Periodic recomputation ensures that the batch layer's output remains up-to-date with the latest real-time data, maintaining consistency between the two processing layers.
What are the trade-offs of using Lambda architecture in big data systems?
Lambda architecture provides both low-latency responses and historical analytics but requires complex setup and maintenance. It can also lead to increased costs due to the need for multiple processing layers and storage solutions.
Try it live
Everything above runs in your browser — open Lambda Architecture: Reconciliation Strip Chart and change the parameters while it is running. Nothing is installed, nothing is uploaded, the whole model lives in one tab.
▶ Open Lambda Architecture: Reconciliation Strip Chart simulation