All Collections
Publish Content
Having trouble uploading a new version of a media file?
Having trouble uploading a new version of a media file?
Shannon Desmond avatar
Written by Shannon Desmond
Updated over a week ago

‘I am trying to replace a file I uploaded to my uConnect Media Library with a new one. I’ve tried deleting the old file and uploading the new version, and for some reason, the old version lives when I click on the link and isn’t being replaced. HELP!’

You are seeing a cached version of the old file that is being served off of your browser or the CDN. In general, caching is not an issue, but a feature that stores data on the visitors computer, or on a CDN (Content Delivery Network) to serve future requests faster. 

Static files which their URL starts with are only cached at the visitor's computer (in our case, for 30 days), and if someone has already visited that URL and therefore has a cached version on their browser, there is little that we can do. The only solution is for the user to clear their browser's cache or do a hard-refresh to force the browser to pull the new version from the server.

For the static files which their URL start with, they are also cached on the CDN before it reaches a visitor's computer, again for 30 days. We do not have automatic invalidation of the CDN cache for updated files yet, but if there is a specific file that has been updated, you can send us a request and we can invalidate the CDN cache for that file for you. Again, if this has already been viewed by a user and cached at their browser, it will be out of our control to push the updated file to that user and it will be up to the user to clear their browser's cache or to do a hard-refresh to pull the updated file from the CDN.

Solution 1:

If redistributing the link to the media file is an option, you can always upload the file with a new name, OR use the same URL but with a cache buster parameter added to the end of the URL (?version=x), e.g. 

The bolded part of the new URL is what you need to add to the URL and this will make the browser and the CDN think that this is a different file and forces them to pull it again. 

Solution 2:

As a best practice, we suggest that you add the file to your uConnect platform as either: 

  1. Resource, here's a refresher on how to add a resource

  2. Add the file as a link on a page or blog post then share the link of the page/post instead of a direct link to a file. 

Did this answer your question?