alibaba/Sentinel

API Gateway exceptionQps not recorded for upstream 5xx | 网关访问后端返回 5xx 时无法统计为异常

Open

#1,706 创建于 2020年8月30日

在 GitHub 查看
 (5 评论) (0 反应) (0 负责人)Java (8,150 fork)batch import
area/gateway-flow-controlgood first issue

仓库指标

Star
 (23,109 star)
PR 合并指标
 (30 天内没有已合并 PR)

描述

Issue Description

bug report

Describe what happened (or what feature you want)

使用spring-cloud-alibbaa集成的sentinel-spring-cloud-gateway-example测试代码 ①通过网关访问后端服务,路由里配置一个错误的端口导致连接不上时,请求返回500,,exceptionQps统计数据有计数 image image ②通过网关访问后端服务,接口能连接上,但是后端服务代码异常,请求同样返回500,,exceptionQps统计数据一直显示为0 image image

Describe what you expected to happen

请求同样是500 希望都能统计

How to reproduce it (as minimally and precisely as possible)

  1. 使用spring-cloud-alibbaa集成的sentinel-spring-cloud-gateway-example测试代码
  2. 将网关路由配置错的端口,请求访问返回500,exceptionQps会计数
  3. 将网关路由配置对的端口,但代码内部使用 10/0 这种错误代码,请求返回500,exceptionQps不会计数

Tell us your environment

spring-cloud-alibaba-gateway,2.2.1.RELEASE

Anything else we need to know?

贡献者指南