You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The read_timeout parameter is currently, correctly, set using setOption() in PhpRedisConnector::createClient() after the connection was created.
The additional sixth argument to connect() was added in ext-redis/3.1.3 (phpredis/phpredis@b56dc4), so older versions won't have it.
However, it might make sense to detect the redis extension version (using phpversion("redis")) and pass the option to the connect() method if possible, as otherwise, the authentication and database selection steps are not subject to the read timeout.
If not, then maybe there should be a comment to explain why it's done this way, to prevent some future "improvement" that moves it to the argument without a version check ;)
Alternatively, just pass the argument to connect() if it's configured in Laravel and skip it otherwise; judging from the ext-redis commits and changelog entry, the read timeout option was broken before 3.1.3 anyway.
The text was updated successfully, but these errors were encountered:
The
read_timeout
parameter is currently, correctly, set usingsetOption()
inPhpRedisConnector::createClient()
after the connection was created.The additional sixth argument to
connect()
was added in ext-redis/3.1.3 (phpredis/phpredis@b56dc4), so older versions won't have it.However, it might make sense to detect the redis extension version (using
phpversion("redis")
) and pass the option to theconnect()
method if possible, as otherwise, the authentication and database selection steps are not subject to the read timeout.If not, then maybe there should be a comment to explain why it's done this way, to prevent some future "improvement" that moves it to the argument without a version check ;)
Alternatively, just pass the argument to
connect()
if it's configured in Laravel and skip it otherwise; judging from the ext-redis commits and changelog entry, the read timeout option was broken before 3.1.3 anyway.The text was updated successfully, but these errors were encountered: