Remove the shard references when database is dropped
The shards map still held a reference to a shard that was dropped which caused the periodic mainteance task to report errors continuously.pull/4580/head
parent
4d277e7772
commit
9046244df3
|
@ -155,7 +155,9 @@ func (s *Store) DeleteDatabase(name string, shardIDs []uint64) error {
|
|||
if shard != nil {
|
||||
shard.Close()
|
||||
}
|
||||
delete(s.shards, id)
|
||||
}
|
||||
|
||||
if err := os.RemoveAll(filepath.Join(s.path, name)); err != nil {
|
||||
return err
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue