I use ThreadSafeClientConnManager
in my app, and a bunch of other classes like HttpStatus, SSLSocketFactory, PlainSocketFactory, SchemeRegistry, etc. But as of API 22 thery're all being marked as deprecated, and I don't see any clear indication as to what replaced them. The documentation jas says to "Please use openConnection() instead. Please visit this webpage for further details", and that doesn't make it very clear what to do. openConnection()
just points to the URL class, and the webpage link is from 2011 that talks about the differences between the Apache classes and HttpUtrlConnection
. So, does that mean that we're supposed to be useign HttpUrlConnection
class from now on? And if that's the case, I thought that it wasn't thread safe (which is why I was using the ThreadSafeClientConnManager
).
Could someone please clarify this for me?