private $skewCacheTTL;
/** @var integer */
private $timeout;
- /** @var string */
- private $directoryHash;
/**
* @param array $params Parameter map:
$this->host = $params['host'];
$this->protocol = $params['protocol'];
$this->directory = trim( $params['directory'], '/' );
- $this->directoryHash = sha1( $this->directory );
$this->encoding = $params['encoding'];
$this->skewCacheTTL = $params['skewTTL'];
$this->baseCacheTTL = max( $params['cacheTTL'] - $this->skewCacheTTL, 0 );
}
$now = microtime( true );
- $key = $this->srvCache->makeKey( 'variable', $this->directoryHash );
+ $key = $this->srvCache->makeGlobalKey(
+ __CLASS__,
+ $this->host,
+ $this->directory
+ );
// Get the cached value or block until it is regenerated (by this or another thread)...
$data = null; // latest config info