Repository navigation
cluster: Create a readonly command lookup table - #3019
michael-grunder wants to merge 1 commit into
Conversation
|
@tillkruss This should solve the issue while still allowing readonly commands to distribute even via |
|
One follow-up: could we keep replica routing for key-based The new test expects |
Right now We can't really pin the commands to an exact instance for // means send to localhost:7000 or any replicas depending on OPT_FAILOVER/OPT_DISTRIBUTE
$rc->rawCommand(['localhost', 7000], 'config', 'set', 'slave-serve-stale-data', 'yes');
// Means send exactly to localhost:7000
$rc->rawCommand(['localhost', 7000, true], 'config', 'set', 'slave-serve-stale-data', 'yes'); |
* Add `@redis-readonly` PHPDoc tags to denote read-only commands. * Create a helper to generate the lookup table of read-only commands with `gperf` * Check if commands are read-only in `rawCommand` invocation. * Fix four more locations where we were allowing `c->readonly` to be inherited Fixes: #3017 See: #3018
bf3c455 to
da5b564
Compare
|
@michael-grunder That could work 👍 |
redis_cluster.stub.phpto denote readonly commandsgperfrawCommandinvocation.c->readonlyto be inheritedFixes: #3017
See: #3018