Re: How to capture HTTP response with the status 500?

"Al Le" <[email protected]>
Newsgroups gmane.comp.jakarta.ant.user
Message-ID <trinity-6276f805-e2dd-4981-a50d-d029962251dd-1484636921426@3capp-gmx-bs50>
> So maybe it's because of the inbuilt JDK's implementation of 
> connection.getInputStream (it throws an exception if the status is 500).

I've debugged it and found out that
the connection object is of type 'sun.net.www.protocol.https.HttpsURLConnectionImpl'
which delegates the getInputStream() method to 'sun.net.www.protocol.http.HttpURLConnection'
which throws an exception if the status is greater than or equal to 400.

This makes me think that it will not be possible to get the full response without a custom implementation of URLConnection.

AL
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.