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

Fix the bug that the Zuul adapter does not exit the entry with parameters #1148

Merged
merged 11 commits into from
Nov 8, 2019

Conversation

wavesZh
Copy link
Contributor

@wavesZh wavesZh commented Nov 7, 2019

Describe what this PR does / why we need it

热点参数限流#基本使用

注意:若 entry 的时候传入了热点参数,那么 exit 的时候也一定要带上对应的参数(exit(count, args)),否则可能会有统计错误

Does this pull request fix one issue?

NONE

Describe how you did it

put holder which contains entry and params into Deque and exit with param

Describe how to verify it

Special notes for reviews

@codecov-io
Copy link

codecov-io commented Nov 7, 2019

Codecov Report

Merging #1148 into master will decrease coverage by 0.01%.
The diff coverage is 0%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #1148      +/-   ##
============================================
- Coverage     42.87%   42.86%   -0.02%     
- Complexity     1540     1541       +1     
============================================
  Files           329      330       +1     
  Lines          9751     9761      +10     
  Branches       1318     1318              
============================================
+ Hits           4181     4184       +3     
- Misses         5055     5063       +8     
+ Partials        515      514       -1
Impacted Files Coverage Δ Complexity Δ
...inel/adapter/gateway/zuul/filters/EntryHolder.java 0% <0%> (ø) 0 <0> (?)
...er/gateway/zuul/filters/SentinelZuulPreFilter.java 14.28% <0%> (-0.3%) 3 <0> (ø)
...apter/gateway/zuul/filters/SentinelEntryUtils.java 13.63% <0%> (-2.16%) 1 <0> (ø)
...p/sentinel/datasource/consul/ConsulDataSource.java 63.76% <0%> (-5.8%) 7% <0%> (ø)
...tinel/slots/block/flow/param/ParamFlowChecker.java 55.4% <0%> (+2.7%) 29% <0%> (+1%) ⬆️
...a/csp/sentinel/slots/statistic/base/LeapArray.java 70.29% <0%> (+2.97%) 34% <0%> (+1%) ⬆️

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 ff5c010...8ea3d68. Read the comment docs.

@sczyh30 sczyh30 added kind/bug Category issues or prs related to bug. to-review To review area/integrations Issues or PRs related to integrations with open-source components labels Nov 7, 2019

private Entry entry;

private Object[] params;
Copy link
Member

Choose a reason for hiding this comment

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

The fields could be final

@sczyh30 sczyh30 changed the title Improve zuul adapter Fix the bug that the Zuul adapter does not exit the entry with parameters Nov 8, 2019
Copy link
Member

@sczyh30 sczyh30 left a comment

Choose a reason for hiding this comment

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

LGTM

@sczyh30 sczyh30 merged commit 73188b4 into alibaba:master Nov 8, 2019
@sczyh30
Copy link
Member

sczyh30 commented Nov 8, 2019

Thanks for contributing!

@sczyh30 sczyh30 removed the to-review To review label Nov 8, 2019
@sczyh30 sczyh30 added this to the 1.7.0 milestone Nov 8, 2019
@wavesZh wavesZh deleted the improve-zuul-adapter branch April 1, 2020 14:04
hughpearse pushed a commit to hughpearse/Sentinel that referenced this pull request Jun 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/integrations Issues or PRs related to integrations with open-source components kind/bug Category issues or prs related to bug.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants