in common/file/FSOFRedis.php [62:90]
public function __construct($config = [])
{
$this->logger = \Logger::getLogger(__CLASS__);
if(isset($config['redis_hosts']))
{
$this->hosts = [];
$address = explode(',', $config['redis_hosts']);
foreach ($address as $node){
list($host, $port) = explode(':', $node);
$this->hosts[] = [$host, $port??FSOFConstants::FSOF_SERVICE_REDIS_PORT];
}
}
if(isset($config['redis_connect_timeout']))
{
$this->connect_timeout = $config['redis_connect_timeout'];
}
if(isset($config['redis_read_timeout']))
{
$this->read_timeout = $config['redis_read_timeout'];
}
if(isset($config['redis_connect_type']))
{
$this->connect_type = $config['redis_connect_type'];
}
if(isset($config['redis_retry_count']))
{
$this->retry = min($config['redis_retry_count'], 1);
}
}