External links image caching #3074
-
I'm working on a Hub created in Spoke with link elements. It seems that after the first time the link is rendered in a Hub the thumbnail image that is shown in the Hub is cached. If the linked page content changes, the Hub thumbnail does not update. As the owner of the Hub and can press "refresh" on the thumbnail in the Hub causing it to update, but when I then leave the Hub the link thumbnail reverts to the earlier cached image. How can I get the Hub thumbnail to update and stay updated to the latest linked content please? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
I believe you're correct in saying this is due to the image being cached on the backend. When you click "refresh", we update an internal "version" for that link that causes the cache to get busted, but only for that particular request. One workaround for this may be add arbitrary query string parameters to the URL, but as far as I know there's no way to explicitly bust the cache that works across sessions. I can't quite tell if the image cache is purged after 5 minutes -- I'm not very familiar with this part of reticulum yet. https://github.com/mozilla/reticulum/blob/master/lib/ret/media_resolver.ex#L368 This may warrant a feature request in either the hubs repo or the reticulum repo. |
Beta Was this translation helpful? Give feedback.
I believe you're correct in saying this is due to the image being cached on the backend. When you click "refresh", we update an internal "version" for that link that causes the cache to get busted, but only for that particular request.
One workaround for this may be add arbitrary query string parameters to the URL, but as far as I know there's no way to explicitly bust the cache that works across sessions. I can't quite tell if the image cache is purged after 5 minutes -- I'm not very familiar with this part of reticulum yet.
https://github.com/mozilla/reticulum/blob/master/lib/ret/media_reso…