mirror of
https://github.com/hrfee/jfa-go.git
synced 2026-01-18 16:47:42 +01:00
When generating the cache and calling userSummary per user, previously the DB was queried for an invite with the ReferrerJellyfinID set to the user's ID. This was fast enough on my test system (~5000 users in ~1.5s), while testing cross-compilation, I found it ran extremely slow on an arm64 build (running through QEMU admittedly), doing ~5000 in ~18s. Instead, a map of IDs to invites/referrals is generated once and queried instead. Initial load now takes ~80ms on my system, and 0.95s through QEMU, and 0.68s on a rockpro64 SBC.