Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. PageCache.php

function PageCache::pass

Sidesteps the page cache and directly forwards a request to the backend.

Parameters

\Symfony\Component\HttpFoundation\Request $request: A request object.

int $type: The type of the request (one of HttpKernelInterface::MAIN_REQUEST or HttpKernelInterface::SUB_REQUEST)

bool $catch: Whether to catch exceptions or not

Return value

\Symfony\Component\HttpFoundation\Response A response object.

1 call to PageCache::pass()
PageCache::handle in core/modules/page_cache/src/StackMiddleware/PageCache.php
Handles a Request to convert it to a Response.

File

core/modules/page_cache/src/StackMiddleware/PageCache.php, line 115

Class

PageCache
Executes the page caching before the main kernel takes over the request.

Namespace

Drupal\page_cache\StackMiddleware

Code

protected function pass(Request $request, $type = self::MAIN_REQUEST, $catch = TRUE) {
    return $this->httpKernel
        ->handle($request, $type, $catch);
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal