Scripting: ability to turn on Lua commands style replication globally.

Currently this feature is only accessible via DEBUG for testing, since
otherwise depending on the instance configuration a given script works
or is broken, which is against the Redis philosophy.
This commit is contained in:
antirez
2015-10-30 10:13:04 +01:00
parent eda06b51fb
commit ff6d296000
4 changed files with 8 additions and 1 deletions

View File

@ -423,6 +423,11 @@ void debugCommand(client *c) {
{
server.active_expire_enabled = atoi(c->argv[2]->ptr);
addReply(c,shared.ok);
} else if (!strcasecmp(c->argv[1]->ptr,"lua-always-replicate-commands") &&
c->argc == 3)
{
server.lua_always_replicate_commands = atoi(c->argv[2]->ptr);
addReply(c,shared.ok);
} else if (!strcasecmp(c->argv[1]->ptr,"error") && c->argc == 3) {
sds errstr = sdsnewlen("-",1);