Consider making use of scrollback fetches in the Combined Feed view #29841
Labels
area: message feed (scrolling)
Scroll behavior, performance, and side-effects (marking as read)
difficult
Issues which we expect to be quite difficult
In #29740, we remove a bit of optimization that Zulip previously did, which is that if you sit in the "Combined feed" view and scroll up, it'll extend the set of messages we have cached in
all_messages_data
for use in visiting other views efficiently.... which would make sense as the API query would be exactly the same one that the "Recent conversations" fetch more button does.See https://github.com/zulip/zulip/pull/29740/files#r1566592303 for details.
I like the implementation simplicity benefits of these changes, so I don't want to go back to having
all_messages_data
deeply entangled throughout that code path. But I wonder a bit if there's a way that we could restore such an optimization more nicely, with a bit of careful checking of fetched message ranges -- maybe even something as simple as "If aGET /messages
API request returns for the combined feed, and the query parameters have the anchor/etc. matching what we would do for anall_messages_data
query, then do that."I guess the other approach would be to implement #16697, which would allow
all_messages_data
to be used as theMessageListData
for the combined feed view directly... I would guess that's probably nicer.The text was updated successfully, but these errors were encountered: