From 8f926a0daeaf4716cfb2e6db143c524da34421de Mon Sep 17 00:00:00 2001 From: Sean McArthur Date: Thu, 28 Feb 2019 16:04:53 -0800 Subject: [PATCH] fix(http2): send INTERNAL_ERROR when user's Service errors --- src/proto/h2/server.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/proto/h2/server.rs b/src/proto/h2/server.rs index d88104cfd8..1c27a9e460 100644 --- a/src/proto/h2/server.rs +++ b/src/proto/h2/server.rs @@ -209,7 +209,12 @@ where } return Ok(Async::NotReady); } - Err(e) => return Err(::Error::new_user_service(e)), + Err(e) => { + let err = ::Error::new_user_service(e); + warn!("http2 service errored: {}", err); + self.reply.send_reset(Reason::INTERNAL_ERROR); + return Err(err); + }, }; let (head, mut body) = res.into_parts();