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
c303e768
Commit
c303e768
authored
Jun 25, 2018
by
antirez
Browse files
Sentinel command renaming: config rewriting.
parent
60df7dbe
Changes
1
Show whitespace changes
Inline
Side-by-side
src/sentinel.c
View file @
c303e768
...
...
@@ -1870,6 +1870,18 @@ void rewriteConfigSentinelOption(struct rewriteConfigState *state) {
rewriteConfigRewriteLine
(
state
,
"sentinel"
,
line
,
1
);
}
dictReleaseIterator
(
di2
);
/* sentinel rename-command */
di2
=
dictGetIterator
(
master
->
renamed_commands
);
while
((
de
=
dictNext
(
di2
))
!=
NULL
)
{
sds
oldname
=
dictGetKey
(
de
);
sds
newname
=
dictGetVal
(
de
);
line
=
sdscatprintf
(
sdsempty
(),
"sentinel rename-command %s %s %s"
,
master
->
name
,
oldname
,
newname
);
rewriteConfigRewriteLine
(
state
,
"sentinel"
,
line
,
1
);
}
dictReleaseIterator
(
di2
);
}
/* sentinel current-epoch is a global state valid for all the masters. */
...
...
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