Skip to content

Commit

Permalink
Set Earliest Version After SS Migration (#1920)
Browse files Browse the repository at this point in the history
Set earliest version after migration
  • Loading branch information
Kbhat1 authored Nov 4, 2024
1 parent 6385633 commit 92325cc
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion tools/migration/ss/migrator.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,12 @@ func (m *Migrator) Migrate(version int64, homeDir string) error {
}
}

// Set latest version in the database
// Set earliest and latest version in the database
err = m.stateStore.SetEarliestVersion(1)
if err != nil {
return err
}

return m.stateStore.SetLatestVersion(version)
}

Expand All @@ -93,6 +98,7 @@ func (m *Migrator) Verify(version int64) error {
}
if !bytes.Equal(val, value) {
verifyErr = fmt.Errorf("verification error: value doesn't match for key %s. Expected %s, got %s", string(key), string(value), string(val))
return true
}
count++
if count%1000000 == 0 {
Expand Down

0 comments on commit 92325cc

Please sign in to comment.