That is indeed a problem: don’t do that. You should write the response to a
file or parse the stream but definitely don’t try generating a 2.3 MB string.
Write a response handler that returns the
HttpEntity
behind the response, then get the InputStream using the
getContent
method, then save that to a file and then process the file.



