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

TJWS returns "Transfer-Encoding: chunked" with empty body

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 2.3-RC1
    • 2.3-beta-1
    • jaxrs
    • None
    • Hide

      Client client = requestFactory.createProxy(Client.class);
      client.putBasic("hello world"); // receives extra null chunk
      client.putData(new URI("/basic"), "hello world2"); // hangs

      Show
      Client client = requestFactory.createProxy(Client.class); client.putBasic("hello world"); // receives extra null chunk client.putData(new URI("/basic"), "hello world2"); // hangs

      If java.acme.serve.Server returns a response with no Content-Length header, it adds a "Transfer-Encoding: chunked" header and sends a final empty chunk with length 0. The empty chunk, which is comprised of five bytes (30 0d 0a 0d 0a)

      1. seem to be illegal, since return code 204 indicates that there the response has no content, and

      2. it confuses HttpClient (4.x), so that org.org.jboss.resteasy.test.finegrain.client.ClientResponseTest hangs.

              rsigal@redhat.com Ronald Sigal
              rsigal@redhat.com Ronald Sigal
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: