-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: build rate limiter on server instance #340
base: main
Are you sure you want to change the base?
Conversation
24e1935
to
9e33c56
Compare
12d4635
to
30d0d5d
Compare
...edule-web-api/src/main/java/com/arextest/schedule/service/ReplayCaseTransmitServiceImpl.java
Show resolved
Hide resolved
...edule-web-api/src/main/java/com/arextest/schedule/service/ReplayCaseTransmitServiceImpl.java
Show resolved
Hide resolved
...edule-web-api/src/main/java/com/arextest/schedule/service/ReplayCaseTransmitServiceImpl.java
Outdated
Show resolved
Hide resolved
arex-schedule-web-api/src/main/java/com/arextest/schedule/common/RateLimiterFactory.java
Outdated
Show resolved
Hide resolved
...edule-web-api/src/main/java/com/arextest/schedule/service/ReplayCaseTransmitServiceImpl.java
Outdated
Show resolved
Hide resolved
arex-schedule-web-api/src/main/java/com/arextest/schedule/common/RateLimiterFactory.java
Show resolved
Hide resolved
return; | ||
} | ||
this.qpsPerInstance = replayPlan.getReplaySendMaxQps(); | ||
this.singleTasks = replayPlan.getCaseTotalCount() / targetInstances.size(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
假设replayPlan.getCaseTotalCount() = 1001, targetInstances.size = 5
this.singleTasks = 200
最终每个serviceLimiterMap中的每个limiter的tasks都是200,那么只会跑1000个case,是否会出现页面执行数量和真正执行数量不一致的场景?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
singleTasks是作为判断连续失败case占比分母(continueFailedCaseCount/singleTasks)
3408c20
to
55c8ed5
Compare
Codecov ReportAttention: Patch coverage is
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## main #340 +/- ##
======================================
Coverage ? 8.13%
Complexity ? 214
======================================
Files ? 220
Lines ? 6588
Branches ? 699
======================================
Hits ? 536
Misses ? 5991
Partials ? 61 ☔ View full report in Codecov by Sentry. |
Quality Gate passedIssues Measures |
7998f05
to
ae04515
Compare
Quality Gate passedIssues Measures |
build rate limiter for per server instance.