From 6c8df98fdd6468517a397ab5b54d66ed35d12ce2 Mon Sep 17 00:00:00 2001 From: Graham McIntire Date: Fri, 20 Feb 2026 08:55:28 -0600 Subject: [PATCH] Update TODO.md with JS reverse index optimization note --- TODO.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/TODO.md b/TODO.md index d84677c..6d2760f 100644 --- a/TODO.md +++ b/TODO.md @@ -25,3 +25,10 @@ time-bounded queries. This is a significant migration effort. Changed `:aprsme` from `write_concurrency` to `read_concurrency`. The only write is `:message_number` increment. If message throughput increases significantly, consider using `:atomics` or `:counters` instead of ETS for the message counter. + +## JS callsign→markerID reverse index + +The `new_packets` handler still scans all `markerStates` when converting old markers to +historical dots. The server now sends `convert_to_historical` callsign keys which narrows +the search, but the scan is O(markerStates) in the worst case. A `Map>` +reverse index maintained by `addMarker`/`removeMarker` would make this O(1).