aboutsummaryrefslogtreecommitdiff
path: root/priv
diff options
context:
space:
mode:
authorrinpatch <rinpatch@sdf.org>2019-08-13 20:34:34 +0300
committerrinpatch <rinpatch@sdf.org>2019-08-13 20:34:34 +0300
commitc1b6952d2abe55668f240947e734127664a4cefa (patch)
treeaea9e5a1d5f877c25bede2f00da224f8f557e03b /priv
parent984d7be1a4b4d1e1024a9f5d5aaee6252c553279 (diff)
downloadpleroma-c1b6952d2abe55668f240947e734127664a4cefa.tar.gz
Mastodon API: Preloading and normalization optimizations
- Try to normalize the activity instead of object wherever possible - Put the `user` key on non-home timelines as well so bookmarks and thread mutes are preloaded there as well - Skip trying to get the user when rendering mentions if the id == as:Public or user's follower collection - Preload the object when getting replied to activities and do not crash if it's not present This almost solves the problem of Pleroma hammering the db with a lot of queries when rendering timelines, the things left are 1. When rendering mentions and the user is not in cache, save it for later and request all uncached users in one go 2. Somehow get rid of needing to get the latest follow activity to detect the value of `requested` in a relationship. (create a database view for user relationship and cache it maybe?)
Diffstat (limited to 'priv')
0 files changed, 0 insertions, 0 deletions