alibaba / alibaba/Sentinel

Dashboard向应用服务发起Metric请求,请求失败后,无详细错误信息

Open
#3,380 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
23.1k
Forks
8.1k
PR merge metrics
No merged PRs in 30d

Description

## Issue Description

Type: *bug report* or *feature request*

### Describe what happened (or what feature you want)

Dashboard向应用服务发起Metric请求,请求失败后,无详细错误信息,客户端也看不到具体原因。
具体是 Dashboard 中 MetricFetcher.fetchOnce() 向客户端获取Metric信息时,客户端响应了内容,但是返回码是失败的。

使用 curl 命令获取metric信息,会提示“Error when retrieving metrics”。

经跟踪,发现是 SendMetricCommandHandler.handle() 中,`list = searcher.findByTimeAndResource(startTime, endTime, identity)` 出现了异常。

![11](https://github.com/alibaba/Sentinel/assets/167858157/782242ae-2924-4a8d-abd7-2e5cbb428112)

> 该函数应该是从本地 metric 文件获取到资源统计数据,**什么情况下会出现异常**?

### Describe what you expected to happen

什么原因导致的这个问题发生?什么情况下会出现这种情况?

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

1.
2.
3.

### Tell us your environment

Sentinel Dashboard 是 1.8.0,应用Sentinel组件依赖版本为 1.4.1

### Anything else we need to know?

在本地和测试环境运行正常,生产环境出现这个问题

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.