Overview
The Reader view can be confusing because posts don't always immediately show up there. If someone is unaware of the current 10-minute cache period, it looks like things are broken.
Users
Reported in #628 - Page cache is too long. /read doesn't show recent posts until after "Updating post cache".
Background
Time-based cache invalidation on the Reader is the easiest, but not the best solution. Instead, we should expire the cache upon certain events occurring.
Implementation
Expire the cache upon these events occurring:
- Publish post to Public-visible collection
- Delete post from Public-visible collection
- Edit post content for post on Public-visible collection (perhaps after a delay?)
- Edit post title for post on Public-visible collection
- Edit metadata for post on Public-visible collection:
- Edit post slug
- Edit publish date
- Edit language
- Move post to / from Public-visible collection
- Post is pinned / unpinned on Public-visible collection
- Collection visibility changed from non-Public to Public, or vice versa
- Public-visible collection is deleted
- Public-visible collection's title is changed
- User with Public collection(s) is silenced or unsilenced