Does OkHttp honors the proxy and non-proxy system settings?
We are in a case where a microservice needs to use a proxy for some calls, but not all. Additionally, OkHttp is used by one of the libraries we rely on, so we do not want to add extra code, we want to use only configuration updates.
So we planned on using the usual system properties -Dhttps.proxyHost
, -Dhttps.proxyPort
, and -Dhttps.nonProxyHosts
as JVM arguments.
I see a lot of discussions regarding the actual support of proxies in OkHpttp, so the question is basically: Does OkHttp honor those system settings?
My testing seems to go in the direction of nonProxyHosts
non being honored, but I prefer to be sure as I get:
What is the recommended approach for scalable cache interceptor in okhttp client
Okhttp client allows caching responses for particular requests by passing file path where it will store the results.
Does OkHttp’s maxRequests/maxRequestsPerHost apply to synchronous requests?
Does OkHttp’s maxRequests/maxRequestsPerHost apply to synchronous/blocking requests? The documentation is not clear.