How does Cache Reserve work with multiple origins?


I’m using Cloudflare Load Balancer and I have two origin servers. One is in Dallas, another one is in Frankfurt.

I’m wonder where Cloudflare stores cache if you have both Tiered Cache and Cache Reserve enabled? Do you pick one R2 location and store all the files there? Or do you pick two separate R2 locations store copies of cache files on both?

Additionally, do you pick an R2 location that’s closest to the origin server, or is origin server’s location not considered in this case?


Hi @pauliusj

Cache Reserve, just stores the cache for a longer time than normal.

Tiered cache:

Tiered Cache uses the size of Cloudflare’s network to reduce requests to customer origins by dramatically increasing cache hit ratios. With data centers around the world, Cloudflare caches content very close to end users. However, if a piece of content is not in cache, the Cloudflare edge data centers must contact the origin server to receive the cacheable content.

Tiered Cache works by dividing Cloudflare’s data centers into a hierarchy of lower-tiers and upper-tiers. If content is not cached in lower-tier data centers (generally the ones closest to a visitor), the lower-tier must ask an upper-tier to see if it has the content. If the upper-tier does not have the content, only the upper-tier can ask the origin for content. This practice improves bandwidth efficiency by limiting the number of data centers that can ask the origin for content, which reduces origin load and makes websites more cost-effective to operate.

Additionally, Tiered Cache concentrates connections to origin servers so they come from a small number of data centers rather than the full set of network locations. This results in fewer open connections using server resources.

Load Balancing is related to the connectivity to your origin, so that if one server is overloaded or down, then the traffic to your goes to the next server.