alibaba / alibaba/Sentinel

System Rules of Cpu Usage has a calculating bug,May occured Double NaN or Infinity returned

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

Description

## Issue Description

Type: *bug report*

### Describe what you expected to happen
sentinel-core.jar com.alibaba.csp.sentinel.slots.system.SystemStatusListener
Sometimes get wrong cpu usage,then block the apps. When System Rule has been set.

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

1. sentinel version: 1.8.0
2. add a log of current cpu usage in com.alibaba.csp.sentinel.slots.system.SystemStatusListener
3. watch it soon you will see NaN of Infinity printed

### Tell us your environment
sentinel version: 1.8.0
os linux 64

Contributor guide

Open the contributing guide

Research direction

Start with com.alibaba.csp.sentinel.slots.system.SystemStatusListener in sentinel-core.jar and reproduce the report on Linux 64 with Sentinel 1.8.0 while logging CPU usage. Done means CPU usage no longer produces NaN or Infinity and a configured system rule does not incorrectly block the application.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
backend, operating-systems
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.