mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2025-12-17 17:51:20 +08:00
filer: close stores if interrupted
This commit is contained in:
@@ -102,6 +102,10 @@ func NewFilerServer(defaultMux, readonlyMux *http.ServeMux, option *FilerOption)
|
||||
|
||||
maybeStartMetrics(fs, option)
|
||||
|
||||
util.OnInterrupt(func() {
|
||||
fs.filer.Shutdown()
|
||||
})
|
||||
|
||||
return fs, nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user