This commit splits compression and serialization into two distinct parts
and adds some utility functions so the user can compress/uncompress
or pack/unpack data explicily.
See #1939
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).
For unknown reasons some methods named differently to Redis
commands (for example setTimeout instead of expire).
This change aligns naming and allows easly remove aliases in future if
we will decide to deprecate them.
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.
This commit implements UNLINK for Redis, RedisCluster, and RedisArray.
To a client library UNLINK behaves identically to DEL so we can use the
same handlers for both.
* Use a precalculated SHA1 of our lock release script and first
attempt to EVALSHA the script while falling back to EVAL if that
fails. This means that the very first time we attempt to release
a lock after server restart or script cache will fail but subsequent
attempts will succeed as Redis will cache the script automatically.
* Reorganized the new locking prototypes by making them static and removing
them from the header file as they never need to be called from outside
of redis_session.c anyway. Did the same for the lock_secret structure
as we don't need to expose the structure externally.
* Consolidated allocation and deallocation of lock pointers such that our
redis_pool "constructor" and "desctructor" handle that as well.
* Updating how we release the lock means we no longer need the new REDIS_G
module globals, so those were removed.
* HOST_NAME_MAX doesn't exist on OSX so added some preprocessor logic around that
Still a WIP as it needs more testing as I'm sure I broke *something* :-)