The interview problem

Practice prompt

An import claims success but the customer finds missing records. Their API list changes while you traverse pages. Diagnose the gap and design a defensible import contract.

Original practice, not a reported company interview. All scenarios and worked numbers are illustrative. Interview date: not applicable. Sources retrieved September 30, 2026.

1. Scope and assumptions

Do not assume a pagination token implies a consistent snapshot. Ask whether the provider guarantees stable ordering, snapshots, change cursors and delete events.

2. Worked approach

source contract
  → snapshot/cursor traversal
  → durable page progress
  → deduplicated import
  → reconciliation

Reproduce the missing record's history against request logs and page boundaries. Prefer a provider-supported snapshot export or stable cursor with documented semantics. Persist import run ID, filters, continuation token and committed page outputs atomically enough to resume without skipping work.

If only mutable listings exist, use stable key ordering where supported, overlap incremental scans and deduplicate by record/version. Reconcile counts and sampled IDs with a source-of-truth export. State that overlap does not guarantee completeness if records can appear and disappear entirely between scans. Negotiate a maintenance snapshot when an exact initial baseline is required.

3. Calculate the example

A list initially contains IDs 1–6. Page one with offset 0 and size 3 returns 1,2,3. If ID 2 is deleted, the remaining list is 1,3,4,5,6; requesting offset 3 returns 5,6 and misses 4. Deduplicating received IDs cannot recover that missing record. Keyset traversal after ID 3 would return 4,5,6 for this example, but still needs semantics for changing keys and new earlier inserts.

4. Failure cases and trade-offs

Saving a token before persisting its page can skip records after a crash. Retrying without deduplication creates duplicates. Filters changed mid-run can invalidate token meaning. A reported total count may itself be approximate or from a different instant.

Snapshot imports offer clear completeness at higher provider cost. Incremental overlap tolerates many operational issues but needs reconciliation and a stated residual risk. Avoid promising exact synchronization from an API that exposes insufficient history.

5. Validate the result

Run controlled inserts/deletes between pages and crash at each checkpoint boundary. Compare the destination against an agreed frozen source sample. Report unresolved discrepancies separately from successful page requests.

6. Interview follow-ups and self-review

How are source deletes represented? Can continuation tokens expire before a long import finishes?

Reward a concrete pagination failure, crash-safe progress, provider-contract awareness and completeness evidence.

Sources and related practice

Technical reference: google.aip.dev — Pagination interface guidance; mutable-list counterexample and import protocol are original.

Exact publication/update date not established in this review. Retrieved September 30, 2026. This reference supports the named technical concept; the proposed workflow and examples are original, not a documented vendor implementation or interview report.

Continue with Reconcile conflicting records across customer systems; Design a change-data-capture pipeline with snapshot recovery.

Continue your preparation

Choose a connected learning path or browse more FDE interviews questions. Read our editorial method and attribution policy.