Skip to content

Conversation

@rzv-me
Copy link
Contributor

@rzv-me rzv-me commented Mar 7, 2025

This is just a backport of the #54934 bugfix from 12.x to 11.x branch.

Using RedisCluster (Laravel Vapor) with compression or serialization doesn't work, because the OPT_SERIALIZER and OPT_COMPRESSION don't exist on the RedisCluster class.

The error: Undefined constant RedisCluster::OPT_SERIALIZER

I replaced $client:: with Redis::.

Even in the PhpRedis extension tests they are using Redis::OPT_SERIALIZER and not RedisCluster::OPT_SERIALIZER https://github.com/phpredis/phpredis/blob/d342e4ac18723607b001deb593c8d45e40bbc4c8/tests/RedisClusterTest.php#L281-L295

@rzv-me rzv-me changed the title [11.x] Backport "Fix issue with using RedisCluster with compression or serialization" [11.x] Backport "Fix issue with using RedisCluster with compression or serialization" Mar 7, 2025
@taylorotwell taylorotwell merged commit 006eada into laravel:11.x Mar 7, 2025
46 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants