Background
https://expensify.slack.com/archives/C05LX9D6E07/p1750073823574879?thread_ts=1749725055.638059&cid=C05LX9D6E07
Problem
recentlyAccessedKeys in OnyxCache is implemented as an Array which has O(n) read/write performance characteristics. It is a LRU but having faster access type should be nice
Solution
Convert recentlyAccessedKeys to Set so we end up with O(1) complexity.
Expected results
Improvement should be visible in the reassure performance tests deltas
Background
https://expensify.slack.com/archives/C05LX9D6E07/p1750073823574879?thread_ts=1749725055.638059&cid=C05LX9D6E07
Problem
recentlyAccessedKeysinOnyxCacheis implemented as anArraywhich has O(n) read/write performance characteristics. It is a LRU but having faster access type should be niceSolution
Convert
recentlyAccessedKeystoSetso we end up with O(1) complexity.Expected results
Improvement should be visible in the reassure performance tests deltas