Fix for #1847 when dealing with NULL multi bulk replies in RedisCluster.
Adds `Redis::OPT_NULL_MULTIBULK_AS_NULL` setting to have PhpRedis
treat NULL multi bulk replies as `NULL` instead of `[]`.
Co-authored-by: Alex Offshore <offshore@aopdg.ru>
Add support for Redis 6 ACLs in the `Redis`, `RedisCluster`, and `RedisArray` classes.
On a related note, it adds a mechanism for users to customize how we generate persistent connection IDs such that they can be grouped in different ways depending on the specific use case required (e.g. it would allow connections to be grouped by username, or by user-defined persistent_id, or both).
Right now cloning the repo and running unit tests will all fail if the
Redis/RedisCluster instances aren't configured with the password
'phpredis'.
This commit simply makes authentication during the tests optional via a
command-line argument.
I our test suite we were only checking if an exception was an instance
of `RedisException` and marking the test 'SKIPPED' if not. This was
masking a failure in the RedisCluster test for testMultiExec by showing
it as skipped when it was actually throwing an exception (not being able
to execute the MULTI across the cluster).
Change the way we accept COUNT and BLOCK such that a user can pass NULL
to mean "no value". This is technically a breaking change, since
previously the value `-1` was used for "no value".
Fixes#1560
Allows ZRANGE to be called either with `true` or `['withscores' => true]` so it's consistent with `ZRANGEBYSCORE` but also backward compatible.
Fixes#1555
Adds an option to process the actual strings in simple string replies as
opposed to translating them to `true`. This only applies to
`rawCommand` and `eval` because as far as I know know vanilla Redis
command attaches any information besides `OK` to simple string replies.
Addresses #1550
This commit updates ZPOPMIN/ZPOPMAX to return the same format that
zRange WITHSCORES and zRangeByScore WITHSCORES does.
In addition the blocking variants BZPOPMIN and BZPOPMAX are implemented.
In the event that the test PHP executable has been built with redis
and/or igbinary support built statically, we don't need to try and
find it by adding --no-php-ini and the extension directives themselves.
This fixes the test execution when php has the required extensions
already.