MCPcopy Create free account
hub / github.com/F-Stack/f-stack / slaveIsInHandshakeState

Function slaveIsInHandshakeState

app/redis-6.2.6/src/replication.c:1421–1424  ·  view source on GitHub ↗

Returns 1 if the given replication state is a handshake state, * 0 otherwise. */

Source from the content-addressed store, hash-verified

1419/* Returns 1 if the given replication state is a handshake state,
1420 * 0 otherwise. */
1421int slaveIsInHandshakeState(void) {
1422 return server.repl_state >= REPL_STATE_RECEIVE_PING_REPLY &&
1423 server.repl_state <= REPL_STATE_RECEIVE_PSYNC_REPLY;
1424}
1425
1426/* Avoid the master to detect the slave is timing out while loading the
1427 * RDB file in initial synchronization. We send a single newline character

Callers 3

roleCommandFunction · 0.85
replicationCronFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected