Skip to content
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

Feature: ExecuteLimit Support #246

Merged
merged 6 commits into from
Oct 29, 2019

Conversation

flycash
Copy link
Member

@flycash flycash commented Oct 26, 2019

What this PR does:

Implement the ExecuteLimitFilter, which used to limit the concurrent requests.

Both the service-level and method-level are supports. But if the user doesn't configure the execute.limit in their service or the value of that is negative, the filter will do nothing.

Which issue(s) this PR fixes:

Fixes #245

Special notes for your reviewer:
The interface RejectedExecutionHandler is used to support this filter, so it has been removed to filter/common;

Does this PR introduce a user-facing change?:

The ExecuteLimitFilter was added to the default filters. 

@codecov-io
Copy link

codecov-io commented Oct 28, 2019

Codecov Report

Merging #246 into develop will increase coverage by 0.08%.
The diff coverage is 78.84%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #246      +/-   ##
===========================================
+ Coverage    64.97%   65.06%   +0.08%     
===========================================
  Files          104      105       +1     
  Lines         6744     6792      +48     
===========================================
+ Hits          4382     4419      +37     
- Misses        1920     1928       +8     
- Partials       442      445       +3
Impacted Files Coverage Δ
...ter/common/impl/rejected_execution_handler_mock.go 0% <ø> (ø)
config/method_config.go 50% <ø> (ø) ⬆️
...common/impl/rejected_execution_handler_only_log.go 100% <100%> (ø)
config/service_config.go 70% <100%> (+1.25%) ⬆️
filter/impl/tps_limit_filter.go 88.23% <100%> (+0.73%) ⬆️
filter/impl/execute_limit_filter.go 73.8% <73.8%> (ø)
protocol/dubbo/client.go 69.07% <0%> (+0.2%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 196481a...32f8233. Read the comment docs.

README_CN.md Show resolved Hide resolved
README_CN.md Outdated Show resolved Hide resolved
Copy link
Contributor

@hxmhlt hxmhlt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Contributor

@fangyincheng fangyincheng left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@AlexStocks AlexStocks merged commit d39a57d into apache:develop Oct 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants