ReverseProxy
in package
Abstract representation of a caching reverse proxy
Tags
Table of Contents
Properties
- $hostname : string
- $port : int
- $ssiProcessor : SsiProcessor
Methods
- __construct() : mixed
- Initializes a reverse proxy instance
- clearCache() : mixed
- Drops all pages cached by this reverse proxy
- clearCachePage() : mixed
- Drops a page cached by this reverse proxy
- getSsiProcessor() : SsiProcessor
- Gets SSI processor used for this proxy
- setSsiProcessor() : mixed
- Sets SSI processor used for this proxy
- clearCachePageForDomainAndPort() : mixed
- Clears a cache page
Properties
$hostname
protected
string
$hostname
Reverse proxy's hostname
$port
protected
int
$port
Reverse proxy's port
$ssiProcessor
protected
SsiProcessor
$ssiProcessor
SSI processor used for this proxy
Methods
__construct()
Initializes a reverse proxy instance
public
__construct(string $hostname, int $port[, mixed $ssiProcessor = null ]) : mixed
Parameters
- $hostname : string
-
Proxy hostname
- $port : int
-
Proxy port
- $ssiProcessor : mixed = null
clearCache()
Drops all pages cached by this reverse proxy
public
clearCache(array<string|int, mixed> $domainsAndPorts) : mixed
Each entry in the array $domainsAndPorts has the following structure:
array(0 =>
Parameters
- $domainsAndPorts : array<string|int, mixed>
-
List of domains and ports that can be used to access this website
clearCachePage()
Drops a page cached by this reverse proxy
public
clearCachePage(string $urlPattern, array<string|int, mixed> $domainsAndPorts) : mixed
Each entry in the array $domainsAndPorts has the following structure:
array(0 =>
Parameters
- $urlPattern : string
-
Drop all pages that match the pattern, for exact format, make educated guesses
- $domainsAndPorts : array<string|int, mixed>
-
List of domains and ports that can be used to access this website
getSsiProcessor()
Gets SSI processor used for this proxy
public
getSsiProcessor() : SsiProcessor
Return values
SsiProcessor —SSI processor used for this proxy
setSsiProcessor()
Sets SSI processor used for this proxy
public
setSsiProcessor(SsiProcessor $ssiProcessor) : mixed
Parameters
- $ssiProcessor : SsiProcessor
-
New SSI processor
clearCachePageForDomainAndPort()
Clears a cache page
protected
abstract clearCachePageForDomainAndPort(string $urlPattern, string $domain, int $port) : mixed
Parameters
- $urlPattern : string
-
Drop all pages that match the pattern, for exact format, make educated guesses
- $domain : string
-
Domain name to drop cache page of
- $port : int
-
Port to drop cache page of