Stale content does not seem to work

We are testing fastly on the free tier and one of our tests relates to stale content.

So I tried these steps:

  • Enable the “Serve stale content on origin failure” option
  • Visit the website and some webpages under it
  • Check with “Check cache” option if the content is cached (it is).
  • Stop the web service on the backend
  • Try to server the cached content while the backend service is off

I would expect the cached (stale) content to be served but I get this instead:

Error 503 Backend unavailable, connection timeout

Backend unavailable, connection timeout

Error 54113

Details: cache-toj-letoxxxxxxx-TOJ dddddddddd dddddddddd

Varnish cache server

I also tried the custom VCL in the documentation:

Am i doing something wrong?

How long have you configured the initial TTL for the object you’re testing? For serving stale content to work properly, you need an initial TTL of over 3700 seconds.

We are talking about the beresp.ttl setting right? The example in the docs had that set to 3600s. I set that to 7200s but still the same.

@theo In that case, it may be time to take this to our support team for diagnostics around the specific object. support.fastly.com is where you can file a ticket, and feel free to link to this thread.