okhttp icon indicating copy to clipboard operation
okhttp copied to clipboard

The calltimeout setting sometimes does not take effect

Open hkj-07 opened this issue 2 years ago • 13 comments

The calltimeout setting sometimes does not take effect. For example, a 10s calltimeout is set, but sometimes it does not close after 10s, and finally closes around 1000s.

hkj-07 avatar Sep 07 '23 09:09 hkj-07

Yikes; that’s severe. I wonder if this is related to full write buffers on the outbound TCP socket. I believe that can be a problem!

swankjesse avatar Oct 06 '23 03:10 swankjesse

@swankjesse What's the theory or observable way to reproduce or fake? A delegating Socket that blocks writes?

yschimke avatar Jan 20 '24 12:01 yschimke

Yeah, a server that doesn’t read anything should do it.

swankjesse avatar Apr 01 '24 01:04 swankjesse

(That’ll only catch a broken write timeout. A broken call timeout should still work fine.)

swankjesse avatar Apr 01 '24 01:04 swankjesse