protected function forward(Request
$request, bool
$catch = false, Response
$entry = null
) { $this->surrogate?->
addSurrogateCapability($request);
// always a "master" request (as the real master request can be in cache)
$response = SubRequestHandler::
handle($this->kernel,
$request, HttpKernelInterface::MAIN_REQUEST,
$catch);
/*
* Support stale-if-error given on Responses or as a config option.
* RFC 7234 summarizes in Section 4.2.4 (but also mentions with the individual
* Cache-Control directives) that
*
* A cache MUST NOT generate a stale response if it is prohibited by an
* explicit in-protocol directive (e.g., by a "no-store" or "no-cache"
* cache directive, a "must-revalidate" cache-response-directive, or an
* applicable "s-maxage" or "proxy-revalidate" cache-response-directive;
* see Section 5.2.2).
*
* https://tools.ietf.org/html/rfc7234#section-4.2.4
*
* We deviate from this in one detail, namely that we *do* serve entries in the
* stale-if-error case even if they have a `s-maxage` Cache-Control directive.
*/