Skip to content

Commit

Permalink
consensus: flush wal on stop (#3297)
Browse files Browse the repository at this point in the history
Should fix #3295
Also partial fix of #3043
  • Loading branch information
ebuchman authored and melekes committed Feb 12, 2019
1 parent 08dabab commit dc6567c
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ Special thanks to external contributors on this release:
- [p2p] [\#3247](https://github.com/tendermint/tendermint/issues/3247) Fix panic in SeedMode when calling FlushStop and OnStop
concurrently
- [p2p] [\#3040](https://github.com/tendermint/tendermint/issues/3040) Fix MITM on secret connection by checking low-order points
- [privval] [\#3258](https://github.com/tendermint/tendermint/issues/3258) Fix race between sign requests and ping requests in socket
- [privval] [\#3258](https://github.com/tendermint/tendermint/issues/3258) Fix race between sign requests and ping requests in socket that was causing messages to be corrupted

## v0.29.1

Expand Down
2 changes: 2 additions & 0 deletions CHANGELOG_PENDING.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,5 @@ Special thanks to external contributors on this release:
### IMPROVEMENTS:

### BUG FIXES:
- [consensus] \#3297 Flush WAL on stop to prevent data corruption during
graceful shutdown
1 change: 1 addition & 0 deletions consensus/wal.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ func (wal *baseWAL) OnStart() error {
// Use Wait() to ensure it's finished shutting down
// before cleaning up files.
func (wal *baseWAL) OnStop() {
wal.group.Flush()
wal.group.Stop()
wal.group.Close()
}
Expand Down

0 comments on commit dc6567c

Please sign in to comment.