mirror of https://github.com/jackc/pgx.git
exitPotentialWriteReadDeadlock stops bgReader
It's not enough to stop the slowWriteTimer, because the bgReader may have been started.pull/1683/head
parent
f512b9688b
commit
95aa87f2e8
|
@ -1732,6 +1732,7 @@ func (pgConn *PgConn) exitPotentialWriteReadDeadlock() {
|
||||||
// The state of the timer is not relevant upon exiting the potential slow write. It may both
|
// The state of the timer is not relevant upon exiting the potential slow write. It may both
|
||||||
// fire (due to a slow write), or not fire (due to a fast write).
|
// fire (due to a slow write), or not fire (due to a fast write).
|
||||||
_ = pgConn.slowWriteTimer.Stop()
|
_ = pgConn.slowWriteTimer.Stop()
|
||||||
|
pgConn.bgReader.Stop()
|
||||||
}
|
}
|
||||||
|
|
||||||
func (pgConn *PgConn) flushWithPotentialWriteReadDeadlock() error {
|
func (pgConn *PgConn) flushWithPotentialWriteReadDeadlock() error {
|
||||||
|
|
Loading…
Reference in New Issue