Uploaded image for project: 'RESTEasy'
  1. RESTEasy
  2. RESTEASY-651

MessageBodyReaderInterceptors get lost when a ClientResponseFailure is thrown

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 2.3.2.Final
    • 2.3.1, 2.3.0.GA
    • jaxrs
    • None

      When trying to read the response entity from a ClientResponseFailure exception the MessageBodyReaderInterceptors are not called so if the response is gzipped it is unable to read the response entity.

      This appears to be caused by the BaseClientResponse.copyFromError(ClientResponse) method which is called by the ClientResponseFailure constructor. It reads the input stream and closes the connection, but does not apply reader interceptors to the stream. It then also removes the Content-Encoding header. Seems like a fix could be to copy the reader interceptors to the new BaseClientResponse and not remove the Content-Encoding header.

              patriot1burke@gmail.com Bill Burke (Inactive)
              jskjons Jeff Skjonsby (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Created:
                Updated:
                Resolved: