we are testing our application using Akka Http to use proxy. We would rather not want code change and so we went with global JVM options of http.proxyHost and http.socksProxyHost.
But, we get java.net.NoRouteToHostException errors when accessing accessing through proxy.
Question, Does Akka Http respects global JVM proxy settings?
Akka HTTP does not use those JDK properties, but instead there is separate Akka HTTP specific config and potentially per client call specific code setup. See docs here: Pluggable Client Transports / HTTP(S) proxy Support • Akka HTTP
Thanks Johan. Is there a config like “non-proxy-hosts” to skip requests to certain domains? I mean, based on what I read and tested, I couldn’t find a generic config to set non-proxy-hosts. I believe we have to manually check for the domain and based on it route through proxy or not.
Is that understanding correct?
Thanks
Sriram
Not through config but with a custom transport you could have arbitrary logic to decide per connection the client wants to make.