mirror of
https://github.com/zulip/zulip.git
synced 2025-11-19 14:08:23 +00:00
This class encapsulates the mapping of stream ids to recipient ids, and it is optimized for bulk use and repeated use (i.e. it remembers values it already fetched). This particular commit barely improves the performance of gather_subscriptions_helper, but it sets us up for further optimizations. Long term, we may try to denormalize stream_id on to the Subscriber table or otherwise modify the database so we don't have to jump through hoops to do this kind of mapping. This commit will help enable those changes, because we isolate the mapping to this one new class.
3.3 KiB
3.3 KiB