Available in all subroutines.
State of the request, with optional additional suffixes describing particulars of the request. Possible values are:
|No state assigned by Varnish yet.|
|We are serving previously-cached content.|
|This request has been previously marked as pass (uncacheable) in |
|We are transitioning into a Hit state but the object's TTL has expired.|
|We are serving a synthetic response.|
|We are serving uncached content.|
|We are serving uncached content that we do not intend to cache for future requests.|
|An error occurred during a background fetch in |
|Transitioned into |
|Returned a 503 because Varnish ran out of memory during header processing.|
|The response will be served internally from another node within the POP.|
|We got back a 304, and served the cached If-Modified-Since content.|
|This request had to wait for a highly-contended object.|
Try it out
fastly_info.state is used in the following solution recipes, which show real world use cases. Click RUN to provision a Fastly service, execute the code on Fastly, and see how the function behaves.
Fastly offers a myriad of different variables that you can log. See and test a large collection here.
User contributed notes
We welcome comments that add use cases, ideas, tips, and caveats. All comments will be moderated before publication. To post support questions, visit our support center and we'll find you the help you need.