-
Notifications
You must be signed in to change notification settings - Fork 26.4k
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
3.0 improve reference bean register #7497
3.0 improve reference bean register #7497
Conversation
* Add grpc status to dubbo status convention * Add triple timeout support
This reverts commit d6c9bf6.
…ilters may have put new values. (apache#7399)
…oblems of PropertyPlaceholderConfigurer (apache#7405)
Codecov Report
@@ Coverage Diff @@
## 3.0 #7497 +/- ##
============================================
+ Coverage 57.61% 58.80% +1.18%
- Complexity 371 372 +1
============================================
Files 1049 1052 +3
Lines 41915 42214 +299
Branches 6245 6278 +33
============================================
+ Hits 24149 24823 +674
+ Misses 14980 14650 -330
+ Partials 2786 2741 -45
Continue to review full report at Codecov.
|
dubbo-common/src/main/java/com/alibaba/dubbo/config/annotation/Reference.java
Show resolved
Hide resolved
…anRegisterPostProcessor
…improve reference bean props populating
…essing , add a new ReferenceBeanBuilder
…nd API are the same)
Codecov Report
@@ Coverage Diff @@
## 3.0 #7497 +/- ##
============================================
+ Coverage 57.17% 58.35% +1.17%
- Complexity 402 404 +2
============================================
Files 1063 1066 +3
Lines 42700 43004 +304
Branches 6387 6421 +34
============================================
+ Hits 24413 25094 +681
+ Misses 15465 15125 -340
+ Partials 2822 2785 -37
Continue to review full report at Codecov.
|
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.
LGTM.
What is the purpose of the change
Improve reference bean register, make xml parsing and annotation processing register bean definition in a similar way, solving the problem of reference injection.
Brief changelog
@DubboReference
annotation and<dubbo:reference />
xml elements:@DubboReference
annotation:@DubboReference
, and register the reference bean definition;Support using
@DubboReference
with@Bean
in java-config class, and support@Conditional
on ReferenceBeanBy post processing
AnnotatedBeanDefinition
which created by java-config@Configuration
class , parsing@DubboReference
with@Bean
and set reference props to bean definition attribute.Improve reference bean props populating
Through the reference key, if the attributes of
@DubboReference
annotation and the<dubbo:reference />
xml bean are the same, they share the same bean definition.The default value of
@DubboReference/@DubboService/@Method/@Argument
annotated int type is changed to -1, and the default value of String type is an empty string.@DubboReference
and@DubboService
annotations addscope
attribute, @method annotation addsparameters
attribute.Others:
and xml/注解方式定义的消费服务bean如何配合@Conditional相关注解 dubbo-spring-boot-project#779
TODO:
Verifying this change
XXXXX
Follow this checklist to help us incorporate your contribution quickly and easily:
[Dubbo-XXX] Fix UnknownException when host config not exist #XXX
. Each commit in the pull request should have a meaningful subject line and body.mvn clean install -DskipTests=false
&mvn clean test-compile failsafe:integration-test
to make sure unit-test and integration-test pass.