We need to find the right CDN solution.
Ideally, what we have is the following:
- No caching or TTLs or any of that nonsense.
- We tell the CDN explicitly when we have a new file.
- We "upload" the new file to the CDN.
- The file is (shortly) available on the CDN when we "upload" it.
In a sense, I think Netlify/Vercel are closest to what we need. They do all of this, except "we" do'nt tell them when we have a new file, we tell them when we have new code (git), they build from the new code, they compare the files, then they decide if files have changed, and explicitly "upload" the new files.
Netlify describes this here: https://www.netlify.com/blog/2021/02/23/terminology-explained-atomic-and-immutable-deploys/
Of course there, they describe their system as "better" than the "old model" using "ftp" -- but I think we really want the old model here. At least, most of the time (when a single survey changes) - because there really is only one file that is changed at a time!
We need to find the right CDN solution.
Ideally, what we have is the following:
In a sense, I think Netlify/Vercel are closest to what we need. They do all of this, except "we" do'nt tell them when we have a new file, we tell them when we have new code (git), they build from the new code, they compare the files, then they decide if files have changed, and explicitly "upload" the new files.
Netlify describes this here: https://www.netlify.com/blog/2021/02/23/terminology-explained-atomic-and-immutable-deploys/
Of course there, they describe their system as "better" than the "old model" using "ftp" -- but I think we really want the old model here. At least, most of the time (when a single survey changes) - because there really is only one file that is changed at a time!