This commit is contained in:
Liang Ding 2023-01-09 20:27:10 +08:00
parent 380384ac0e
commit 68b0f4e8b3
No known key found for this signature in database
GPG key ID: 136F30F901A2231D
2 changed files with 36 additions and 0 deletions

View file

@ -1255,6 +1255,12 @@ func autoFixIndex() {
})
size := len(paths)
redundantPaths := treenode.GetRedundantPaths(box.ID, paths)
for _, p := range redundantPaths {
treenode.RemoveBlockTreesByPathPrefix(p)
}
missingPaths := treenode.GetNotExistPaths(box.ID, paths)
for i, p := range missingPaths {
reindexTreeByPath(box.ID, p, i, size)