Part of the response can be served closer to the user
What a CDN stores
A CDN is a distributed content delivery layer. It serves stored images, styles and other cacheable responses without always contacting the origin server. A personalized response cannot automatically be shared across users. In this task, 80% of requests are static and 20% always require the origin. A CDN node near users is called an edge node.
Hit and miss
A cache hit means the CDN already has a suitable fresh response. A miss goes to origin. If the edge served 700 of 1,000 requests/s, origin would receive 300, within its capacity of 400. Reduce actual origin load, rather than merely adding an attractive intermediate node.
Delivery and freshness
TTL determines how long a response is fresh. Longer retention usually increases reuse but may violate update requirements. This static content has a 60-second limit. The stand’s hit function is simplified and described in the model: it does not predict a real CDN’s hit rate from TTL alone.
How to compare options
Start with a short TTL and watch origin misses. Then increase it to the allowed limit. Cost includes the CDN and traffic to origin; latency averages fast hits and slower origin accesses. Maximum TTL is not a solution if content becomes too stale.
Task
1,000 requests/s: 80% static files, 20% personalized responses. Origin handles 400 requests/s. Add a CDN; content cannot be considered fresh for more than 60 s.
Steady flow for 60 s. Effective hit share follows a teaching warm-up function: 0.8×TTL/(TTL+10). Dynamic 20% always reach the origin. Edge capacity is 1500 hits/s; origin capacity is 400 misses/s. The hit function is an assumption, not a universal CDN formula.
- Add a CDN from the component panel.
- Choose TTL based on origin traffic and freshness requirements.
- Check that useful requests are served within budget.