In production should I just be using the Apache client?
krtko
04/06/2019, 6:25 AM
Is there one you'd recommend? Binary size isn't a concern and we don't really need any real features.
d
dave
04/06/2019, 6:28 AM
I personally default to OkHttp, but for no particular reason. They're all solid performers. I'd probably choose Jetty last because I've never used it in prod personally.
k
krtko
04/06/2019, 6:29 AM
Sweet thanks
d
dave
04/06/2019, 6:29 AM
OkHttp also has an easy way to configure listeners so you can measure things like DNS lookup latency, which is pretty niche, but useful
k
krtko
04/06/2019, 7:51 AM
I've been using OkHTTP for requests, but our the server mostly just talks to a database and server as an HTTP end point.
d
dave
04/06/2019, 9:27 AM
BTW, you can test the entire thing without using an HTTP client - because of the symmetric interface you can just replace the OkHttp() interface with your app and test completely in-memory