ensure field bit depth is set when restoring shard

we have to manually set the cache value here bc it wont get set until the node is restarted otherwise
This commit is contained in:
reesporte 2021-12-15 16:09:45 -06:00
parent 600494c724
commit c59ce837b3

8
api.go
View file

@ -2768,6 +2768,14 @@ func (api *API) RestoreShard(ctx context.Context, indexName string, shard uint64
if err != nil {
return err
}
bd, err := view.bitDepth([]uint64{shard})
if err != nil {
return err
}
err = fld.cacheBitDepth(bd)
if err != nil {
return err
}
}
return nil