I am making a simple request for a file using HttpClient from the Apache Commons. Here is my current code:
httpclient = new DefaultHttpClient(); http
You can use httpget.abort() method to abort the request mid way.
httpget.abort()
See example here