4 ms·
I thought what and when to cache was one of the hardest problems in computer science.
by patates 4y ago
I thought what and when to cache was one of the hardest problems in computer science.
- endisneigh 4y agoSomething like Mastodon is likely 90% reads, or even more. How often is the OP editing their post? When they post, cache it. Kind of like what I did by including it in my original post. Caching is a hard problem because sometimes invalidation results in serious consequences, therefore knowing when to invalidate becomes potentially intractable. In this case there would be few, if any.
- jibe 4y agoit was cache invalidation, and naming things. Just throwing stuff in cache is easy.
- CyberDildonics 4y agoWhy would it be difficult to cache static text?