Given the GracefulShutdownHandler#decrementRequests function!
A thread T1 is at A. During this instant:
- A thread T2 handles a new request GracefulShutdownHandler#handleRequest
- A thread T3 shutdown the handler GracefulShutdownHandler#shutdown() but after T2 has started to handle its request (ie. after the if (shutdown) condition.
In this case even if there is an active request, T0 will call shutdownComplete()