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
6097d14d
Unverified
Commit
6097d14d
authored
Mar 17, 2021
by
Wen Hui
Committed by
GitHub
Mar 17, 2021
Browse files
fix wrong comment for data_age unit (#8665)
fix typo
parent
f657315e
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/cluster.c
View file @
6097d14d
...
@@ -3090,7 +3090,7 @@ void clusterFailoverReplaceYourMaster(void) {
...
@@ -3090,7 +3090,7 @@ void clusterFailoverReplaceYourMaster(void) {
/* This function is called if we are a slave node and our master serving
/* This function is called if we are a slave node and our master serving
* a non-zero amount of hash slots is in FAIL state.
* a non-zero amount of hash slots is in FAIL state.
*
*
* The g
a
ol of this function is:
* The go
a
l of this function is:
* 1) To check if we are able to perform a failover, is our data updated?
* 1) To check if we are able to perform a failover, is our data updated?
* 2) Try to get elected by masters.
* 2) Try to get elected by masters.
* 3) Perform the failover informing all the other nodes.
* 3) Perform the failover informing all the other nodes.
...
@@ -3135,7 +3135,7 @@ void clusterHandleSlaveFailover(void) {
...
@@ -3135,7 +3135,7 @@ void clusterHandleSlaveFailover(void) {
return
;
return
;
}
}
/* Set data_age to the number of seconds we are disconnected from
/* Set data_age to the number of
milli
seconds we are disconnected from
* the master. */
* the master. */
if
(
server
.
repl_state
==
REPL_STATE_CONNECTED
)
{
if
(
server
.
repl_state
==
REPL_STATE_CONNECTED
)
{
data_age
=
(
mstime_t
)(
server
.
unixtime
-
server
.
master
->
lastinteraction
)
data_age
=
(
mstime_t
)(
server
.
unixtime
-
server
.
master
->
lastinteraction
)
...
...
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