3

How can i disconnect an org.​apache.​http.​client.HttpClient object?
I'm creating it like this but it doesn't have any disconnect() or getHttpConnectionManager!

HttpClient httpclient = new DefaultHttpClient();

Thanks

Ariyan
  • 14,760
  • 31
  • 112
  • 175

1 Answers1

4

Use

httpClient.getConnectionManager().shutdown();

See examples.

Note: getHttpConnectionManager was from HttpClient 3.1.

skaffman
  • 398,947
  • 96
  • 818
  • 769