The data arrived late. That does not mean the event just happened.
Event time, CDC, and correction policies determine whether a daily report can still be trusted.
The pipeline clock is not the business clock.
A payment happens on Monday at 11:58 PM but is not delivered until Tuesday at 2:00 AM. A report by arrival time records it on Tuesday. A sales report by event time records it on Monday. Both may be valid for different purposes, but the labels need to be clear. Offline devices, queues, and source corrections make late events normal, not some magical exception.
Store event_time and ingested_at, along with the timezone convention. Add the source update time if it is available. These fields answer different questions. One generic timestamp column is often the start of a misunderstanding that only appears during reconciliation.
Incremental processing needs a change signal.
A filter like created_at > checkpoint only captures records created after the boundary. It may miss an update to an old order, a cancellation, or a deletion. A lookback window can help when delay is understood, but it does not guarantee that older corrections will arrive. The strategy should follow source behavior, not the shortest query.
A daily snapshot may be enough for a small product reference table. Frequently changing transaction data may fit CDC better. Its operating costs include log position, retention, snapshot bootstrap, and recovery. Do not pay for streaming complexity on every table just to make the architecture look busy.
CDC does not answer the business question for you.
The Debezium PostgreSQL connector describes an initial snapshot and processing changes from the log. Consumers need to translate creates, updates, and deletes into the right current state or history. Counting every update message as a new sale is obviously wrong. A repeated paid status does not prove there was a second payment.
Define identity, change versions, and sink behavior. Keep current-state tables separate from change history if consumers need both. Test a connector that has been stopped for a long time: is the source log still available, or is a new snapshot required? Real-time systems still need a recovery plan.
A watermark is not proof that all data has arrived.
Beam distinguishes event time, windows, watermarks, and late data. A watermark helps estimate event-time progress. It does not guarantee that every old event has arrived. Decide when an initial result is published, how long revisions are accepted, and where data beyond the boundary goes. Fast, complete, and cheap require negotiation.
In the visual, a one-hour boundary includes two events worth Rp100,000. A six-hour boundary includes all four, worth Rp180,000. Waiting improves completeness in this example but delays finalization. Six hours is not a universal recommendation. It is a learning parameter you can change.
Revisions are fine. Silent revisions are not.
Mark a result as provisional if corrections are still accepted. Store the cutoff, calculation version, and update time for each partition. For a closed report, late data can go into a correction queue or an adjustment period according to business policy. Changing history without telling consumers can invalidate decisions they have already made.
Monitor the lateness distribution, including high percentiles and extreme tails. Separate late data that was processed from data sent to quarantine. If the dashboard is fast because slow events were discarded, its speed is hiding work. Completeness needs to be measured alongside freshness.
An example to inspect.
-- Two intentionally different perspectives
SELECT DATE(event_time), SUM(amount_idr)
FROM payments GROUP BY 1;
SELECT DATE(ingested_at), COUNT(*)
FROM payments GROUP BY 1;
-- Set the business timezone before using DATE in production.
An old order changes to refunded without changing created_at. Is created_at > checkpoint enough?
No. You need an update or delete signal, a reread of the relevant scope, or another change mechanism that fits the source.
Keep these three things.
- Separate event time from arrival time.
- Define the revision boundary and correction path.
- Test old updates, deletes, and recovery.
Sources, not slogans.
Primary references reviewed on 7 November 2026. The explanation, examples, and visual were prepared by RapiApp. The diagram simplifies the topic for learning. The article explains its assumptions and limits.
- Beam: Windowing and late data
- Debezium: PostgreSQL connector
Continue the foundations.
- Who is this row about? Get identity right before building the pipeline.
- The pipeline ran twice. Why did revenue double too?
- The data arrived late. That does not mean the event just happened.