alibaba / Sentinel

A powerful flow control component enabling reliability, resilience and monitoring for microservices. (面向云原生微服务的高可用流控防护组件)
https://sentinelguard.io/
Apache License 2.0
22.45k stars 8.04k forks source link

热点参数并发数限流[BUG] #3436

Open CuzTNT opened 4 months ago

CuzTNT commented 4 months ago

Issue Description

Type: bug report

Describe what happened

并发测试热点参数,限流不稳定。 限制并发数为10,并发20次,多次测试,部分通过次数超过10,部分符合预期

Describe what you expected to happen

并发限制为10

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

  1. apifox 并发测试

Tell us your environment

1.8.3

Anything else we need to know?

ParameterMetric.getThreadCount方法先于addThreadCount调用,同一时刻多个线程进入getThreadCount时获取当前线程数均为null