In plain words
A CDN keeps copies of your responses in data centres around the world, so visitors get them from somewhere nearby, and your Cache-Control headers decide what may be stored and for how long.
Where you see it
Harbor's marketing pages, docs and build assets go through Cloudflare. A visitor in Sydney gets the pricing page from a Sydney data centre instead of from Harbor's servers in Virginia, and the cf-cache-status response header says HIT or MISS.
What goes wrong
- Caching a page with someone's account on it
If a signed-in response is cached as public, the CDN can hand one customer's billing page to the next visitor. Mark personal responses private or no-store, and check that no CDN rule overrides that.
- Long cache times on files whose names never change
An app.js cached for a year means visitors keep the old code after a deploy. Long lifetimes are only safe for files with a content hash in their name; HTML should be short-lived or revalidated.
- Purging everything as the plan
Purging the whole CDN after every change throws away every cached file at once and sends a burst of traffic to your servers. Use short lifetimes with stale-while-revalidate, or purge only the URLs or tags that changed.
What to tell your agent
Quick check
Sign in to earn +10 XP for itAfter a deploy, some Harbor visitors get a broken page: new HTML loading an old app.js from the CDN. What's the lasting fix?