File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -337,8 +337,6 @@ error_code Replica::InitiatePSync() {
337
337
338
338
RETURN_ON_ERR (SendCommand (StrCat (" PSYNC " , id, " " , offs)));
339
339
340
- LOG (INFO) << " Starting full sync" ;
341
-
342
340
// Master may delay sync response with "repl_diskless_sync_delay"
343
341
PSyncResponse repl_header;
344
342
@@ -353,8 +351,9 @@ error_code Replica::InitiatePSync() {
353
351
354
352
// we get token for diskless redis replication. For disk based replication
355
353
// we get the snapshot size.
356
- if (snapshot_size || token != nullptr ) { // full sync
357
- // Start full sync
354
+ if (snapshot_size || token != nullptr ) {
355
+ LOG (INFO) << " Starting full sync with Redis master" ;
356
+
358
357
state_mask_.fetch_or (R_SYNCING);
359
358
360
359
io::PrefixSource ps{io_buf.InputBuffer (), Sock ()};
@@ -394,6 +393,8 @@ error_code Replica::InitiatePSync() {
394
393
CHECK (ps.UnusedPrefix ().empty ());
395
394
io_buf.ConsumeInput (io_buf.InputLen ());
396
395
TouchIoTime ();
396
+ } else {
397
+ LOG (INFO) << " Re-established sync with Redis master with ID=" << id;
397
398
}
398
399
399
400
state_mask_.fetch_and (~R_SYNCING);
You can’t perform that action at this time.
0 commit comments