Skip to content

Commit

Permalink
Merge pull request #721 from bloxapp/migration-7
Browse files Browse the repository at this point in the history
Migration 7: clean operator removals corruptions
  • Loading branch information
amirylm authored Oct 14, 2022
2 parents e02092f + 5dd1489 commit 1c6339e
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
16 changes: 16 additions & 0 deletions migrations/migration_7_clean_operator_removals_corruptions.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
package migrations

import (
"context"
)

var migrationCleanOperatorRemovalCorruptions = Migration{
Name: "migration_7_clean_operator_removal_corruptions",
Run: func(ctx context.Context, opt Options, key []byte) error {
nodeStorage := opt.nodeStorage()
if err := nodeStorage.CleanRegistryData(); err != nil {
return err
}
return opt.Db.Set(migrationsPrefix, key, migrationCompleted)
},
}
1 change: 1 addition & 0 deletions migrations/migrations.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ var (
migrationCleanExporterRegistryData,
migrationCleanValidatorRegistryData,
migrationCleanSyncOffset,
migrationCleanOperatorRemovalCorruptions,
}
)

Expand Down

0 comments on commit 1c6339e

Please sign in to comment.