Fix the bug of getting the wrong current flow QPS in ClusterFlowChecker (#972)
This commit is contained in:
parent
56c73698cb
commit
17365f3d5f
|
|
@ -64,7 +64,7 @@ final class ClusterFlowChecker {
|
||||||
return new TokenResult(TokenResultStatus.FAIL);
|
return new TokenResult(TokenResultStatus.FAIL);
|
||||||
}
|
}
|
||||||
|
|
||||||
double latestQps = metric.getAvg(ClusterFlowEvent.PASS_REQUEST);
|
double latestQps = metric.getAvg(ClusterFlowEvent.PASS);
|
||||||
double globalThreshold = calcGlobalThreshold(rule) * ClusterServerConfigManager.getExceedCount();
|
double globalThreshold = calcGlobalThreshold(rule) * ClusterServerConfigManager.getExceedCount();
|
||||||
double nextRemaining = globalThreshold - latestQps - acquireCount;
|
double nextRemaining = globalThreshold - latestQps - acquireCount;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue