Skip to content

Commit

Permalink
Set persisted commit number when server recovers. Else it was not abl…
Browse files Browse the repository at this point in the history
…e to repsond if the first call to server was a get call after recovery (#786)
  • Loading branch information
pradeepyadavmsft authored Jan 20, 2023
1 parent 8155ba4 commit 6e0bea0
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cs/src/core/FasterLog/FasterLog.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1918,6 +1918,8 @@ private void RestoreLatest(out Dictionary<string, long> iterators, out byte[] co
iterators = CompleteRestoreFromCommit(info);
cookie = info.Cookie;
commitNum = info.CommitNum;
// After recovery persisted commitnum remians 0 so we need to set it to latest commit number
persistedCommitNum = info.CommitNum;
beginAddress = allocator.BeginAddress;
if (readOnlyMode)
allocator.HeadAddress = long.MaxValue;
Expand Down

0 comments on commit 6e0bea0

Please sign in to comment.