You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The plan9_arm builder sometimes fails in net/http/transport tests with output like:
--- FAIL: TestTransportPersistConnLeak
transport_test.go:1032: goroutine growth: 59 -> 162 -> 66 (delta: 7)
transport_test.go:1033: too many new goroutines
This test has a fixed sleep time of 100ms to allow goroutines to exit after CloseIdleConnections is called. On a Raspberry Pi running many simultaneous tests, this is not always long enough.
A similar function TestTransportPersistConnLeakShortBody has a sleep time of 400ms for the same purpose (originally 50ms but revised upwards in CL 12960046). This seems to be plenty of time for plan9_arm, but on faster hosts will usually be much more than necessary.
Instead of just increasing the sleep time, I propose replacing the fixed sleep in both tests by calls to a new function which will do shorter sleeps in a loop until the number of goroutines reaches the desired threshold or an overall timeout expires.
The text was updated successfully, but these errors were encountered:
The plan9_arm builder sometimes fails in net/http/transport tests with output like:
This test has a fixed sleep time of 100ms to allow goroutines to exit after CloseIdleConnections is called. On a Raspberry Pi running many simultaneous tests, this is not always long enough.
A similar function
TestTransportPersistConnLeakShortBody
has a sleep time of 400ms for the same purpose (originally 50ms but revised upwards in CL 12960046). This seems to be plenty of time for plan9_arm, but on faster hosts will usually be much more than necessary.Instead of just increasing the sleep time, I propose replacing the fixed sleep in both tests by calls to a new function which will do shorter sleeps in a loop until the number of goroutines reaches the desired threshold or an overall timeout expires.
The text was updated successfully, but these errors were encountered: