Files
bitvid/js/state
google-labs-jules[bot]andPR0M3TH3AN ecc9041cbd perf: optimize ProfileCache.clearMemoryCache to O(1)
Refactor ProfileCache memoryCache from a flat Map to a nested Map (Pubkey -> Section -> Data).
This allows clearing a user's cache in O(1) time instead of O(N) by deleting the user's entry directly, avoiding a full scan of all cache keys.

Benchmark showed improvement from ~58ms to ~0.0014ms for clearing a user in a cache with 20,000 users (100,000 entries).

Co-authored-by: PR0M3TH3AN <[email protected]>
2026-02-05 19:18:36 +00:00
..