💾 Archived View for makeworld.space › amfora-wiki › Caching.gmi captured on 2024-07-08 at 23:16:47. Gemini links have been rewritten to link to archived content
View Raw
More Information
⬅️ Previous capture (2022-07-16)
-=-=-=-=-=-=-
Caching
Pages
Home
Subscriptions
Caching
Bookmarks
Configuration
Client Certificates
Handling Other URL Schemes
Opening or streaming non text files
Proxying
Source Code Highlighting
Amfora caches documents (aka "pages") it loads, to reduce latency: if you're navigating through history, or simply just returning to the same page again. This wiki page outlines which pages are cached and when. Note that Amfora's cache algorithm has changed for over time, this page just explains what is done for the latest release.
What kinds of pages are cached?
- All text pages loaded over the network are cached * Unless a client cert was sent with the request: client certs means some sort of application is being used, which is often dynamic * Unless the request was due to a redirect: redirects are often used for changing content that shouldn't be cached, like redirecting to the same page when clicking a "button"
- Gemini pages loaded from a proxy are cached
- `about:` pages are not cached, although sometimes they're static and in-memory anyway, like `about:version`
- `file://` pages are not cached
Cache invalidation
- The cache is optionally limited by size and/or number of pages, as set in the configuration file * The pages cached first will be removed first
- It is also configurably limited by a timeout, so if the page was cached more than X seconds ago, it will be kept in memory but never used again * This out-of-date page being kept in memory will be replaced if an up-to-date version of the page is cached * It could also be removed due to size or number of pages limits
configuration file
If you'd like to support Amfora development, you can sponsor me through Ko-Fi or Github Sponsors. Feel free to submit a PR as well! Thanks.
Ko-Fi
Github Sponsors