Fix bug where the last write gets dropped and no other write follows on the buffer. Was causing relpay to error out
parent
e9d39cabaa
commit
2e41160ea4
|
@ -43,7 +43,6 @@ func (self *WriteBuffer) Write(request *protocol.Request) {
|
|||
case self.writes <- request:
|
||||
return
|
||||
default:
|
||||
log.Info("Write buffer full, pausing that shit")
|
||||
select {
|
||||
case self.stoppedWrites <- *request.RequestNumber:
|
||||
return
|
||||
|
@ -99,6 +98,10 @@ func (self *WriteBuffer) replayAndRecover(missedRequest uint32) {
|
|||
}
|
||||
}
|
||||
}
|
||||
if req == nil {
|
||||
log.Error("REPLAY: emptied channel, but no request set")
|
||||
return
|
||||
}
|
||||
log.Info("REPLAY: Emptied out channel")
|
||||
shardIds := make([]uint32, 0)
|
||||
for shardId, _ := range self.shardIds {
|
||||
|
|
Loading…
Reference in New Issue