Skip to content

Commit

Permalink
Revert "Revert "offset""
Browse files Browse the repository at this point in the history
This reverts commit c2e89cd.
  • Loading branch information
Baoyi Chen committed Dec 9, 2023
1 parent 038b916 commit 14226ea
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -300,13 +300,13 @@ public long parse() throws IOException {
// we should set repl_id, repl_offset, repl_stream_db after full sync done to avoid losing data.
Configuration configuration = replicator.getConfiguration();

String replId = configuration.setCookie(REPL_ID, null);
String replId = configuration.setCookie(REPL_ID, "?");
if (replId != null) configuration.setReplId(replId);

String replOffset = configuration.setCookie(REPL_OFFSET, null);
String replOffset = configuration.setCookie(REPL_OFFSET, "-1");
if (replOffset != null) configuration.setReplOffset(parseLong(replOffset));

String replStreamDB = configuration.setCookie(REPL_STREAM_DB, null);
String replStreamDB = configuration.setCookie(REPL_STREAM_DB, "-1");
if (replStreamDB != null) configuration.setReplStreamDB(parseInt(replStreamDB));
return offset;
}
Expand Down

0 comments on commit 14226ea

Please sign in to comment.