Embed Notice
HTML Code
Corresponding Notice
- Embed this noticeMastodon has Status and Account entities in the API. Both rarely change and Status is maybe even immutable. Except for one problem: stats. Follower count, following count, reply, favourite, reblog count. We want to cache entities in RAM for performance, but we can't because the stats change every 5 seconds.
But we don't always need stats in the UI, so GraphQL helps us solve this problem by letting us drop stats from the response. Then we can return cached entities resulting in better performance.