My program always get stuck for 30 seconds on
[DEBUG] SingleClientConnManager - Get connection for route HttpRoute[{}->http://foobar.com]
Further investigation suggests this is due to ipv4 fallback.
Is there anyway to force ipv4 on httpclient to resolve the issue?
P.S.
I believe it is a IPv4 problem because curl -L04 http://foobar.com is an instantanious download, while curl -L06 http://foobar.com produces curl: (6) Couldn't resolve host 'foobar.com'
When you run your program use: