Skip to content

Commit

Permalink
Merge pull request #4185 from goller/fix/close-metastore-bolt-db
Browse files Browse the repository at this point in the history
fix(metadata): close store on exit
  • Loading branch information
tonistiigi authored Aug 29, 2023
2 parents 9bfc68c + e0ccc47 commit 6ae419d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions worker/base/worker.go
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,9 @@ func NewWorker(ctx context.Context, opt WorkerOpt) (*Worker, error) {

func (w *Worker) Close() error {
var rerr error
if err := w.MetadataStore.Close(); err != nil {
rerr = multierror.Append(rerr, err)
}
for _, provider := range w.NetworkProviders {
if err := provider.Close(); err != nil {
rerr = multierror.Append(rerr, err)
Expand Down

0 comments on commit 6ae419d

Please sign in to comment.