Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 6e229ca

Browse files
committed
fix: clean up idle http conns on wsconncache close
See https://github.com/coder/coder/actions/runs/4346769070/jobs/7593243836
1 parent d8abe37 commit 6e229ca

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

coderd/wsconncache/wsconncache.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,7 @@ func (c *Cache) Acquire(r *http.Request, id uuid.UUID) (*Conn, func(), error) {
121121
}
122122
c.connMap.Delete(id.String())
123123
c.connGroup.Forget(id.String())
124+
transport.CloseIdleConnections()
124125
_ = conn.Close()
125126
}()
126127
return conn, nil

0 commit comments

Comments
 (0)