“Did the event arrive?” is not the same as “Can I trust this signal?”
For systems that collect events from many devices, a single ingestion-success metric is not enough to explain data quality. A pipeline can accept an event that arrived late. A retry can look like a new observation. A repeated value can be a valid heartbeat. An offset gap can be worth investigating without proving that data was lost.
I built FleetScope as a small, reproducible lab to separate these cases instead of collapsing them into one health score.
Keep different failure modes different.
Freshness
Measures event-to-ingestion delay using p50, p95, mean and maximum. Future-dated timestamps are isolated rather than silently treated as negative latency.
Retries and replay integrity
Tracks explicit resend markers, duplicate event IDs and conflicting replays separately. A repeated value is not automatically classified as a retry.
Offset continuity
Inspects observed topic/partition offset windows for gaps, repeated offsets and reordering. An observed gap is a diagnostic prompt—not proof of data loss.
Signal cadence
Compares successive first-delivery observations with declared expected intervals to estimate missing emission slots. The result is explicitly an estimate, not a loss counter.
A reproducible path from event generation to operator view.
The backend uses Python, Pydantic, FastAPI and SQLite. Event filtering, substring search and pagination are performed in SQL. Prometheus output stays at run-level to avoid high-cardinality vehicle and event labels. The browser UI is dependency-free HTML, CSS and JavaScript.
event stream → schema validation → freshness / retry / replay analysis → offset + cadence diagnostics → SQLite persistence → FastAPI + dashboard + CSV + Prometheus
Same seed. Three different operating conditions.
The bundled scenarios use seed 23, 12 synthetic vehicle identifiers and 80 base events per identifier. The generator adds resend deliveries, so final accepted record counts are higher than the base-event count.
| Profile | Valid records | Resends | Late events | Offset gaps | Estimated missing samples |
|---|---|---|---|---|---|
| Clean | 961 | 1 | 9 | 0 | 0 |
| Balanced | 981 | 33 | 91 | 7 | 11 |
| Stress | 1,001 | 78 | 253 | 19 | 28 |
Measure the prototype honestly.
The largest local microbenchmark generated and analysed 50,906 synthetic records in 13.0943 seconds, with 111.98 MiB of peak traced Python allocations. This was one run on Python 3.13.5 in a Linux environment. It is a scale check, not a statistically reliable latency estimate or a production-throughput claim.
The local suite contains 30 tests and reports 95.68% line coverage. A real Uvicorn smoke run exercised the UI, API, event filters, CSV export, Prometheus endpoint and OpenAPI. A Python 3.10–3.13 CI matrix is configured, but remote CI results have not yet been used as evidence here.
Clear boundaries are part of the engineering.
Batch, not streaming
The current analyser processes event batches. It is not a bounded-state real-time streaming engine and does not claim end-to-end consumer lag.
No broker truth
The prototype does not ingest broker high-water marks, committed consumer offsets or retention metadata. Offset gaps cannot prove missing messages.
No real fleet feed
There is no Kafka cluster, distributed compute, vehicle connection, production service or Tesla data in this project.
Next technical steps
A streaming analyser with checkpointing, broker metadata, per-signal data contracts, OpenTelemetry instrumentation and concurrent HTTP load tests would be meaningful extensions.
I wanted to understand where a “healthy” pipeline can still mislead us.
FleetScope is a learning and engineering exercise—not a claim that the hard problems are solved. I’m interested in data infrastructure, telemetry reliability and systems where software decisions depend on the quality of incoming signals. Technical feedback and thoughtful collaboration are welcome.