RedirectCacheService

class \TYPO3\CMS\Redirects\Service\RedirectCacheService

Ensure to clear the cache entry when a sys_redirect record is modified, also the main pool for getting all redirects.

Attributes

#[Autoconfigure]
$public: true

Table of Contents

Properties

$cache  : FrontendInterface
$connectionPool  : ConnectionPool

Methods

__construct()  : mixed
getRedirects()  : array
Fetches all redirects available to the system, grouped by domain and regexp/nonregexp
rebuildAll()  : void
Rebuild cache for each distinct redirect source_host.
rebuildForHost()  : array
Rebuilds the cache for all redirects, grouped by host as well as by regular expressions and respect_query_parameters.

Properties

Methods

getRedirects()

Fetches all redirects available to the system, grouped by domain and regexp/nonregexp

public getRedirects(string $sourceHost) : array

Parameters

$sourceHost : string

Return values

array

rebuildAll()

Rebuild cache for each distinct redirect source_host.

public rebuildAll() : void

rebuildForHost()

Rebuilds the cache for all redirects, grouped by host as well as by regular expressions and respect_query_parameters.

public rebuildForHost(string $sourceHost) : array

Does not include hidden or deleted redirects, but includes the ones with dynamic starttime/endtime.

Parameters

$sourceHost : string

Return values

array
On this page