ORIGINAL COMPANY-CONTEXT PRACTICE
Reconstruct a synthetic vehicle event timeline
Original practice scenario: A mobility simulator uploads buffered vehicle events after intermittent connectivity. Device clocks may drift and events may arrive several hours late.
Written for independent practice using company context; this is not a verified question from a company interview.
A REASONED APPROACH
Model answer.
Keep device sequence, event time and ingestion time as distinct fields. A useful timeline should preserve uncertainty and gaps instead of manufacturing a precise global ordering.
Work through it
- Identify each device session and event, validate monotonic sequence numbers within a session and deduplicate retransmitted batches.
- Estimate clock offsets only from available synchronization evidence; retain raw timestamps and mark intervals whose ordering cannot be established reliably.
- Test clock resets, session restarts, missing sequences and repeated uploads, and make late-event reconciliation update derived views deterministically.
Tradeoffs to discuss
- Waiting for late events improves completeness but delays dashboards; provisional windows need an explicit correction policy.
Common pitfalls
- Sorting solely by server arrival time misrepresents offline activity.
- Do not infer exact physical causality from timestamps whose uncertainty overlaps.