okhttp icon indicating copy to clipboard operation
okhttp copied to clipboard

WifiManager.WifiLock

Open wmulligan opened this issue 12 years ago • 1 comments

This is not directly a issue with OkHttp, but I was curious what your suggestion is.

Should applications always use the WifiManager.WifiLock before executing a network call with OkHttp?

I've seen scenarios where the device shows it has a wifi connection, but okHttp throws an exception about "unknown host". Seconds later, everything works. Should OkHttp have a bit of retry logic in it to reattempt connections if we get "unknown host"? Or are applications expected to continuously retry those requests?

wmulligan avatar Apr 17 '14 17:04 wmulligan

Please ask general questions on StackOverflow using the 'okhttp' tag. This will not only let the community participate in answering, but also is a much more searchable place for future travelers looking for similar information.

http://stackoverflow.com/questions/ask?tags=okhttp

JakeWharton avatar Apr 17 '14 17:04 JakeWharton