Is the Edge Cache TTL *always* respected?

If I set the Edge TTL for some images to a very long period (e.g. 1 month), does that mean that our servers will receive only the initial request(s) from your network and then all the subsequent requests during the month are served directly from Cloudflare?

Or is it possible that if the image is not requested frequently Cloudflare will remove it from its cache (thus not respecting the Edge TTL)?

Basically I wonder which one of the following is true:

  1. an image with Edge Cache TTL=1month is kept for 1 month in the cache (i.e. caching equal to 1month)
  2. an image with Edge Cache TTL=1month is kept for at most 1 month, but can be removed from cache earlier, for example if it is not requested very frequently (i.e. caching less than or equal to 1 month)

In particular I am on a Business plan.

It’s #2 for the reasons you speculated. Not only that, but each edge server has its own cache, so a HIT in FRA data center won’t mean the next visit in LAX will be a HIT.

cloudflare follow MRU algorithms for edge cache.

Any official reference?
What is the cache size per account?

There is no guarantee that Edge Cache will be stored for a month even if you set Edge Cache TTL to a month.

If the image request is not frequent then cache gonna be cleared from edge cache, it means CF won’t respect the TTL.

Source: Edge Cache TTL

Sorry I type the wrong algorithm. It is LRU algo. Once asked this question to support.

This topic was automatically closed after 14 days. New replies are no longer allowed.