Skip to content

Commit

Permalink
Merge pull request #191 from swapnilgm/fix/cleanup
Browse files Browse the repository at this point in the history
[hotfix] Cleanup in-memory events before stopping snapshotter
  • Loading branch information
Swapnil Mhamane authored Aug 22, 2019
2 parents ebec08d + fb0d8b2 commit 795902a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pkg/snapshot/snapshotter/snapshotter.go
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,7 @@ func (ssr *Snapshotter) CollectEventsSincePrevSnapshot(stopCh <-chan struct{}) (
return false, nil
}
case <-stopCh:
ssr.cleanupInMemoryEvents()
return true, nil
}
}
Expand Down Expand Up @@ -441,6 +442,7 @@ func (ssr *Snapshotter) snapshotEventHandler(stopCh <-chan struct{}) error {
return err
}
case <-stopCh:
ssr.cleanupInMemoryEvents()
return nil
}
}
Expand Down

0 comments on commit 795902a

Please sign in to comment.