Merge pull request #3985 from nats-io/oor-raft

Only process out of resources condition from raft layer if err matches explicitly.
This commit is contained in:
Derek Collison
2023-03-23 08:39:15 -07:00
committed by GitHub

View File

@@ -3408,8 +3408,10 @@ func (n *raft) setWriteErrLocked(err error) {
}
n.werr = err
// For now since this can be happening all under the covers, we will call up and disable JetStream.
go n.s.handleOutOfSpace(nil)
if isOutOfSpaceErr(err) {
// For now since this can be happening all under the covers, we will call up and disable JetStream.
go n.s.handleOutOfSpace(nil)
}
}
// Capture our write error if any and hold.