Try
↑ ↓ move↵ openesc close

Interview prep / CDNs and edge caching

Senior · CDNs and edge caching · System design interview question

What is an origin shield, and when would you add one?

Sketch your own answer first, then compare it with the one below.

A strong answer

It is a cache layer between the edges and the origin. Each edge that misses asks the shield first. If many edges miss on the same object, the shield sends one request to the origin and answers the rest from its copy.

Add one when many edges means many misses for the same object, which is common for long-tail content and for a new object that all edges request at once. It raises origin offload without changing each edge's hit ratio.

The costs are an extra hop on a double miss, one more layer to run and purge, and a single region that every miss passes through. A shield placed far from the origin can add latency, so put it near the origin.

Sources

Learn it by running it

The cdns and edge caching lesson explains the mechanism behind this question, and its lab lets you change the parameters and watch the effect.

Your progress is saved in this browser. Sign in to keep it on every device. Privacy · Terms