Subscribe free
Alloconomy 21 Nov 2026 3 min read

Choose what the source must retain

A nightly product table shows $20 at both Monday and Tuesday close.

The interview prompt

A nightly product table shows $20 at both Monday and Tuesday close. A pricing analyst wants the revenue impact of an afternoon promotion. Meanwhile you must initialize a CDC pipeline without dropping concurrent writes. What can you establish?

A snapshot boundary is part of the data

Both daily snapshots are compatible with an uninterrupted $20 price and with a four-hour $15 promotion. Retrieve the price-change log or transaction-level charged prices before estimating promotion exposure. Charged prices can show what buyers paid. They still omit the exposure of visitors who saw the offer and bought nothing.

For a new CDC pipeline, request a consistent snapshot tied to a known log position using the source’s supported protocol. Rows in the snapshot establish the initial state. Subsequent changes establish how it evolved. A snapshot taken through a series of unrelated reads can combine a parent row from before a transaction with a child row from after it. Record which boundary you used and how long changes remain available for replay.

Walk through an update during the initial copy and a deletion immediately afterward. The final mirror must contain the most recent valid state. A historical event product may instead retain the deletion as a tombstone. Verify both at a common cutoff against source counts or checksums and sample identities. Two equally sized tables can contain entirely different keys.

The model behind the answer

A nightly extract can support a daily catalog. If a title changes price twice between extracts, two end-of-day copies cannot establish the intervening price. A transaction log or explicit price-change event can preserve those transitions. Start with the historical question and inspect what the source emits. Asking for a streaming pipeline cannot recover events the source has already discarded.

With change data capture (CDC), an update or deletion is itself input. A common bootstrap pairs a consistent initial snapshot with changes after a known log position. Coordinate that boundary so concurrent writes cannot disappear between the two reads. Preserve source keys, operation, position, and ordering information at the scope the source guarantees.

A row update to a dispatch record can be a corrected address. Counting every CDC update as another shipment confuses a database write with the business event. Define the mapping and try it on an insert, an amendment, and a deletion before using it for daily volume. Debezium’s PostgreSQL connector

Review the handoff from snapshot to change log

Ask the agent for an initialization plan with a recorded snapshot position and a precise rule for the first log record to apply. Start the reviewer’s snapshot at position 40, update the price at 41 during the copy, and delete the product at 42.

Reviewer decision. After replay the product must be absent from the current projection. If the business also bought an intraday history, both transitions must be recoverable from retained input. Two identical end-of-day prices cannot establish the missing afternoon price or the sales that occurred at it.

Further reading. Designing Data-Intensive Applications, 2nd ed., on the snapshot offset and the history discarded by compaction.

One more question

A source log retains two days of changes. Your connector was down for three. Can you promise exact intermediate history after restarting?

Check your reasoning

Only with another retained copy of the missing log or equivalent evidence. A fresh snapshot can restore current state. It cannot reconstruct all intermediate mutations. Mark the history gap, choose a recovery boundary, and tell consumers which measurements remain complete.

Previous · Give a correction somewhere to go · Next · Crash after the write · Complete series map