okhttp applicationInterceptor vs networkIntercepto...
# squarelibraries
c
okhttp applicationInterceptor vs networkInterceptor I'm using Chucker as a networkInterceptor to see network requests. I am seeing 0 network requests. Moved to using plain ol' interceptor and I can see that I do in fact make a network request (like I thought) but it failed due to SSLHandshakeException. Why would a networkInterceptor not show an SSLHandshakeException but reg interceptor does?
j
Because if TLS fails there is no connection over which to send the request
c
Interesting... TIL! Thank you!
and here i thought networkInterceptor would be the silver bullet. time to revisit my chucker impl...
related to the above... admittedly out of okhttp territory (I think) but sorta rubber ducking anyway. So I spent another 2 days or so trying to debug. Basically having a discussion with my backend/ops team to try to figure out why staging isn't working. I use https://www.ssllabs.com/ssltest/analyze.html because I think Jesse recommended it once. If I use my production url, then everything works in my android app and ssllabs says everything is good to go. but pointing to staging... my ops teams wants us to connect over VPN (sucks, but fine I'll install a vpn on my phone) now I can access the staging website etc from Chrome, but my android app still can't make network requests to staging. I end up with that SSLHandshakeException. any idea why that is?
Only thing that sucks is that iOS works fine. so it's just being labelled as an "android" issue. 😭