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

Optimize LeastActiveLoadBalance select. #2161

Closed
wants to merge 6 commits into from

Conversation

carryxyh
Copy link
Member

@carryxyh carryxyh commented Aug 1, 2018

Now the select is select a random one when there are several least active invokers and all of them are in warm up.
After this pr, it will select also by weight and warm up.

ISSUE:
#904

Now the select is select a random one when there are several least active invokers and all of them are in warm up.
After this pr, it will select also by weight and warm up.
@codecov-io
Copy link

codecov-io commented Aug 1, 2018

Codecov Report

Merging #2161 into master will increase coverage by 0.03%.
The diff coverage is 80.64%.

Impacted file tree graph

@@             Coverage Diff             @@
##             master   #2161      +/-   ##
===========================================
+ Coverage     54.26%   54.3%   +0.03%     
- Complexity     5103    5110       +7     
===========================================
  Files           559     559              
  Lines         24947   24981      +34     
  Branches       4447    4453       +6     
===========================================
+ Hits          13538   13565      +27     
- Misses         9373    9381       +8     
+ Partials       2036    2035       -1
Impacted Files Coverage Δ Complexity Δ
...e/src/main/java/com/alibaba/dubbo/rpc/Invoker.java 36.36% <100%> (ø) 0 <0> (ø) ⬇️
...g/apache/dubbo/config/AbstractInterfaceConfig.java 80.78% <57.14%> (-0.75%) 81 <0> (ø)
...pc/cluster/loadbalance/LeastActiveLoadBalance.java 71.42% <75%> (ø) 6 <0> (ø) ⬇️
...o/common/extension/support/ActivateComparator.java 70.9% <84.37%> (+29.24%) 19 <0> (+7) ⬆️
...apache/dubbo/common/extension/ExtensionLoader.java 72.94% <85.71%> (+0.23%) 118 <0> (+2) ⬆️
.../dubbo/remoting/transport/netty4/NettyChannel.java 60% <0%> (-6.25%) 21% <0%> (-2%)
...org/apache/dubbo/rpc/filter/ActiveLimitFilter.java 83.33% <0%> (-5.56%) 6% <0%> (-1%)
...e/dubbo/remoting/transport/netty4/NettyServer.java 72.13% <0%> (-3.28%) 9% <0%> (-1%)
...dubbo/rpc/protocol/dubbo/CallbackServiceCodec.java 77.2% <0%> (-1.48%) 29% <0%> (ø)
...apache/dubbo/rpc/protocol/dubbo/DubboProtocol.java 58.33% <0%> (-0.84%) 30% <0%> (-1%)
... and 3 more

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 d62e15d...16fe0fb. Read the comment docs.

jerrick-zhu and others added 2 commits August 2, 2018 14:08
* support @activate for compatible

* add testcase for @activate compatible

* add LICENSE for test class

* import format
@ralf0131
Copy link
Contributor

ralf0131 commented Aug 2, 2018

Hi,

Would you please add some unit test for this change?

yunxiyi and others added 3 commits August 2, 2018 16:34
Now the select is select a random one when there are several least active invokers and all of them are in warm up.
After this pr, it will select also by weight and warm up.
@carryxyh carryxyh closed this Aug 2, 2018
@carryxyh
Copy link
Member Author

carryxyh commented Aug 3, 2018

Sorry for rebase sth wrong into current branch, the new pr is here:

#2172

@carryxyh carryxyh deleted the feature/optimize-leastactive branch August 16, 2018 10:38
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.

6 participants