koa icon indicating copy to clipboard operation
koa copied to clipboard

Client disconnect

Open siakc opened this issue 1 year ago • 1 comments

Suppose a route takes 60 seconds to respond. Client disconnects for some reason at second 25. Will Koa continue running middles or it will terminate context? I ask this to know how to handle some slow routes.

siakc avatar Jun 11 '24 14:06 siakc

I guess koa will continue the request and stop when it responds and hits the writable check: in respond and then reach response.writable.

TommyDew42 avatar Jun 28 '24 15:06 TommyDew42