Use new "response stream disconnected" status for disconnections during proxying#2503
Use new "response stream disconnected" status for disconnections during proxying#2503
Conversation
justin-mp
left a comment
There was a problem hiding this comment.
The code changes look good to me (in conjunction to the internal PRs to the schema as needed by outcome.capnp), but I'm surprised that there's no test change for workerd. Is this because RequestObserver::reportFailure in workerd is an empty implementation, and, as such, doesn't change with this code?
906b7f5 to
1f27176
Compare
Yeah, as far as I can tell, we don't really have test coverage in workerd for Most workerd tests seem to be |
...to be used when an exception is thrown due to disconnection during deferred proxying, which is common when the client or server hangs up early, particularly when proxying websockets. Should allow us to differentiate these cases from those where JS is still running, such that a thrown exception could still be caught and handled by the worker. Also, add instrumentation to report failure during deferred proxying.
1f27176 to
3fc25de
Compare
* [worker] Document response stream disconnected error This change documents the `responseStreamDisconnected` error `outcome` seen in CloudFlare worker logs and error metrics. Previously, this outcome doesn't appear to be documented, but presents as an error in metrics and presents as a non-error entry in the CloudFlare Worker Logs. This change aims to reduce confusion going forward. Changes introducing `responseStreamDisconnected`: cloudflare/workerd#2503 * Update src/content/docs/workers/observability/errors.mdx * Moved content under metrics heading --------- Co-authored-by: ToriLindsay <tgalatro@cloudflare.com>
Add new responseStreamDisconnected request status, to be used when an exception is thrown due to disconnection during deferred proxying, which is common when the client or server hangs up early, particularly when proxying websockets. Should allow us to differentiate these cases from those where JS is still running, such that a thrown exception could still be caught and handled by the worker.
Also, add instrumentation to report failure during deferred proxying.