Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
f1de29b3
Commit
f1de29b3
authored
Sep 10, 2018
by
antirez
Browse files
Slave removal: scripting.c logs and other stuff fixed.
parent
53fe558e
Changes
1
Show whitespace changes
Inline
Side-by-side
src/scripting.c
View file @
f1de29b3
...
@@ -777,7 +777,7 @@ int luaRedisSetReplCommand(lua_State *lua) {
...
@@ -777,7 +777,7 @@ int luaRedisSetReplCommand(lua_State *lua) {
flags = lua_tonumber(lua,-1);
flags = lua_tonumber(lua,-1);
if ((flags & ~(PROPAGATE_AOF|PROPAGATE_REPL)) != 0) {
if ((flags & ~(PROPAGATE_AOF|PROPAGATE_REPL)) != 0) {
lua_pushstring(lua, "Invalid replication flags. Use REPL_AOF, REPL_
SLAVE
, REPL_ALL or REPL_NONE.");
lua_pushstring(lua, "Invalid replication flags. Use REPL_AOF, REPL_
REPLICA
, REPL_ALL or REPL_NONE.");
return lua_error(lua);
return lua_error(lua);
}
}
server.lua_repl = flags;
server.lua_repl = flags;
...
@@ -998,6 +998,10 @@ void scriptingInit(int setup) {
...
@@ -998,6 +998,10 @@ void scriptingInit(int setup) {
lua_pushnumber(lua,PROPAGATE_REPL);
lua_pushnumber(lua,PROPAGATE_REPL);
lua_settable(lua,-3);
lua_settable(lua,-3);
lua_pushstring(lua,"REPL_REPLICA");
lua_pushnumber(lua,PROPAGATE_REPL);
lua_settable(lua,-3);
lua_pushstring(lua,"REPL_ALL");
lua_pushstring(lua,"REPL_ALL");
lua_pushnumber(lua,PROPAGATE_AOF|PROPAGATE_REPL);
lua_pushnumber(lua,PROPAGATE_AOF|PROPAGATE_REPL);
lua_settable(lua,-3);
lua_settable(lua,-3);
...
@@ -1484,7 +1488,7 @@ void scriptCommand(client *c) {
...
@@ -1484,7 +1488,7 @@ void scriptCommand(client *c) {
const char *help[] = {
const char *help[] = {
"DEBUG (yes|sync|no) -- Set the debug mode for subsequent scripts executed.",
"DEBUG (yes|sync|no) -- Set the debug mode for subsequent scripts executed.",
"EXISTS <sha1> [<sha1> ...] -- Return information about the existence of the scripts in the script cache.",
"EXISTS <sha1> [<sha1> ...] -- Return information about the existence of the scripts in the script cache.",
"FLUSH -- Flush the Lua scripts cache. Very dangerous on
slave
s.",
"FLUSH -- Flush the Lua scripts cache. Very dangerous on
replica
s.",
"KILL -- Kill the currently executing Lua script.",
"KILL -- Kill the currently executing Lua script.",
"LOAD <script> -- Load a script into the scripts cache, without executing it.",
"LOAD <script> -- Load a script into the scripts cache, without executing it.",
NULL
NULL
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment