jkap

CEO of posting

butch jewish dyke
part of @staff, cohost user #1
married to @kadybat

This user can say it
osu stats


🐘 mastodon
xoxo.zone/@jkap
🖼️ icon credit
twitter.com/osmoru
🐦 twitter
not anymore lol

to start, some background:

we cache your timeline because building it every time you wanted to see it would be Slow and we can't have that. this cache is just a big list of post IDs because we can fetch posts quickly, we just can't build the list quickly.

when you publish a post, we fire off a series of background jobs that insert that post into all your followers' cached timelines. previously we were doing this in order based on when someone followed you (so earlier followers would see your posts sooner). this was kind of dumb and led to there being a sizable disparity in when posts would be seen on high-follower accounts.

so we randomized it. when you publish a post, we grab a list of all your followers, shuffle it, and then start handing out the post in that new random order. this means users at the end of the list will, on average, see posts sooner. yes this means users who followed early will, on average, see posts later. this doesn't actually make any material difference until you hit around 3k followers though so don't worry about it.

enjoy your slightly sooner / later post viewing.


this is a change that occurred to me as an option in the shower. my initial message in the chat was "i don't know if we should do this, but i also can't think of a ton of reasons why we shouldn't do this, and it'll be like two lines of code max, so we may as well"


You must log in to comment.

in reply to @jkap's post:

I’m surprised you precache the timeline instead of generate and cache it when requested. If someone doesn’t log in for multiple days, all of the effort to cache their timelines is misspent, right?

yeah i should clarify: we generate the first time when a user requests it and then keep it around for up to a week (assuming they don’t log in again) so the expensive part isn’t wasted

Does the bookmarked tag feed use something similar? I've noticed that the first page or two loads quickly, but by three or four in it takes several seconds.

nope, only things using this system are the timeline and notification feeds. we might swap to something similar for the bookmarked tag feed at some point, my best guess is it's just a perf issue with the query we're using (which definitely has room for improvement).