Description
Rossen Stoyanchev opened SPR-17341 and commented
Currently HttpWebHandlerAdapter suppresses logging of unhandled exceptions from writing to the response that are associated with a client going away. This is useful with streaming responses and was introduced in #18523. However as is clear from #21790 similar exceptions may also occur during request handling while making calls to a remote service, and arguably logging for those should not be suppressed.
This ticket is to explore the possibility of differentiating between the two and suppressing logging only of the former, but not of the latter kind. One option may be to wrap exceptions from ServerHttpResponse#writeWith
with something like the Reactor Netty AbortedException and use that to differentiate between server response writing and other socket exception.
Affects: 5.0.9
Issue Links:
- Suppress Reactor Netty "disconnected client" exceptions the logs [SPR-17257] #21790 o.s.h.s.r.ReactorHttpHandlerAdapter is polluting the logs
- WebFlux SSE controller does not detect disconnected client [SPR-15306] #18523 WebFlux SSE controller does not detect disconnected client