You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2020/01/16 17:44:30 UTC

[Bug 64080] Graceful shutdown does not occur for connected clients that have not yet submitted their request payload

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

Mark Thomas <ma...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|normal                      |enhancement
                 OS|                            |All

--- Comment #1 from Mark Thomas <ma...@apache.org> ---
I'll note that:
- there is a similar situation with requests in the keep-alive state;
- the issue was introduced largely as a result of the switch from blocking IO
to non-blocking IO.

Are you expecting Tomcat to process these requests normally (within some
configured timeout or set of timeouts for each stage) or is cleanly returning a
503 an acceptable response?

Looking at the existing code, processing the requests normally is a much more
invasive change that returning a 503.

A likely issue with a 503 is that clients won't read it until they have sent
the entire request so the Connector's maxSwallowSize configuration becomes a
factor as well.

It looks like changes would be required;
- in the Processor.service() implementations to always process the request on
the first iteration around the processing loop
- in Endpoint.stopInternal() to add a delay / wait between pause() (which stops
the Acceptor) and stopping the Poller (NIO/APR) / closing the active
connections (NIO2)

I'm moving this to an enhancement

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