You are viewing a plain text version of this content. The canonical link for it is here.
Posted to httpclient-users@hc.apache.org by Mohit Anchlia <mo...@gmail.com> on 2012/01/09 22:49:25 UTC

hangs when using setRequestEntity behaviour

I am running  a test in eclipse that hangs when I use
setRequestEntity. When I uncomment it doesn't hang and the server
returns error. Can someone please give me some pointers?

           ByteArrayRequestEntity entity = new
ByteArrayRequestEntity(body.getBytes(), "application/xml");
            httpMethod.setRequestHeader("Content-type", "application/xml");
            httpMethod.setRequestEntity(entity); // Hangs if I leave
it uncommented
            log.info("Call " + httpMethod.getURI());
            client.executeMethod(httpMethod);

---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
For additional commands, e-mail: httpclient-users-help@hc.apache.org