https://bz.apache.org/bugzilla/show_bug.cgi?id=62569

            Bug ID: 62569
           Summary: Async servlet setReadListener does not work if post
                    request data arrives much later than headers
           Product: Tomcat 9
           Version: 9.0.10
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Servlet
          Assignee: dev@tomcat.apache.org
          Reporter: zdap...@google.com
  Target Milestone: -----

In async mode, servlet sets a ReadListener, and invokes onDataAvailable
callbacks.
If a client first sends out a POST request headers, then 2 seconds later sends
out the payload. The ReadListener callbacks will never be invoked, and the
client never receives a response. Glassfish 5.0 does not have this issue. This
may not be a serious problem for HTTP/1.1 and servlet 3.1, but it is a problem
for HTTP/2 and servlet 4.0 because HTTP/2 is ful-duplex.

See the servlet code snippet in the Java EE tutorial example:
https://javaee.github.io/tutorial/servlets013.html

Client side command:

telnet localhost 8080

POST /asyncioservlet HTTP/1.1
Host: localhost
Content-Type: application/json
Transfer-Encoding: chunked

10
{"key1":"value"}
0

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to