Recently I faced with the same problem described here http://stackoverflow.com/questions/28785085/how-to-prevent-hangs-on-socketinputstream-socketread0-in-java
In short any blocked-socket library including apache HttpClient may be blocked forever because of following reported but still not fixed issues:
I’ve switched to HttpAsyncClient 4.1.1 but faced with following issue: Wowza Streaming Engine include org.apache.http.* components inside wms-restlet-2.2.2. My HttpAsyncClient 4.1.1 requires httpcore-4.4.4 and I included all necessary dependencies into my module jar manifest
but it looks like Wowza includes lower version and my code failed due to the fact that Wowza classloader load all classes: wowza system classes and all module classes. This way one module cannot have it’s own library version necessary. So it’s impossible to have two complex Modules installed on one server as each Module uses different library version. Getting more and more complex Wowza starts using common java libraries itself and this problem getting more and more important for us. Our Module still supports all Wowza versions starting from 2.2.4 and we cannot upgrade our dependencies since out Module has common dependency with Wowza.
To build our Module we use maven template https://github.com/WMSPanel/wowza-maven-template/blob/master/pom.xml and one of the build step is to copy all module’ dependencies into separate folder in wowza/lib like wowza/lib/wmspanel-lib.
I’m pleased developing many years for wonderful Wowza server. Wowza as well as modules getting more and more complex and it looks like there is only one way to avoid these problems - wowza have to use separate classloader for each Module and shouldn’t include it’s own dependencies into classpath as Module or it’s dependencies may depend on another version of the same libraries. This way a Module or Wowza core may depend on different versions and all will works perfect. Of course wowza should include wowza api classes into Module classloader.
There is another way though. Each Module can implement it’s own classloader. I think it’s bad idea as it’s very complex task for individual Module authors.
Wowza team what do you think about this proposal ? Can we expect to have this functionality in the next server version ?