Skip to content

issue#1447: NettyHelper in netty extension populated Logger "InternalLogger" in netty.#1704

Closed
beiwei30 wants to merge 1 commit intoapache:masterfrom
beiwei30:netty-logging
Closed

issue#1447: NettyHelper in netty extension populated Logger "InternalLogger" in netty.#1704
beiwei30 wants to merge 1 commit intoapache:masterfrom
beiwei30:netty-logging

Conversation

@beiwei30
Copy link
Copy Markdown
Member

What is the purpose of the change

to fix issue reported by #1447: NettyHelper in netty extension populated Logger "InternalLogger" in netty.

Brief changelog

don't log context info if it's not from dubbo code base

Verifying this change

Follow this checklist to help us incorporate your contribution quickly and easily:

  • Make sure there is a GITHUB_issue filed for the change (usually before you start working on it). Trivial changes like typos do not require a GITHUB issue. Your pull request should address just this issue, without pulling in other changes - one PR resolves one issue.
  • Format the pull request title like [Dubbo-XXX] Fix UnknownException when host config not exist #XXX. Each commit in the pull request should have a meaningful subject line and body.
  • Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
  • Write necessary unit-test to verify your logic correction, more mock a little better when cross module dependency exist. If the new feature or significant change is committed, please remember to add integration-test in test module.
  • Run mvn clean install -DskipTests & mvn clean test-compile failsafe:integration-test to make sure unit-test and integration-test pass.
  • If this contribution is large, please follow the Software Donation Guide.

@codecov-io
Copy link
Copy Markdown

Codecov Report

Merging #1704 into master will increase coverage by 0.07%.
The diff coverage is 23.07%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #1704      +/-   ##
============================================
+ Coverage     35.37%   35.45%   +0.07%     
- Complexity     3765     3775      +10     
============================================
  Files           628      628              
  Lines         30963    30987      +24     
  Branches       5438     5449      +11     
============================================
+ Hits          10954    10987      +33     
+ Misses        18109    18106       -3     
+ Partials       1900     1894       -6
Impacted Files Coverage Δ Complexity Δ
...com/alibaba/dubbo/common/logger/LoggerFactory.java 25.49% <0%> (-2.78%) 3 <0> (ø)
...remoting/transport/netty4/logging/NettyHelper.java 23.58% <100%> (-0.23%) 2 <0> (ø)
...ba/dubbo/common/logger/support/FailsafeLogger.java 13.63% <28.57%> (+0.22%) 4 <1> (-1) ⬇️
...g/context/annotation/DubboConfigConfiguration.java 50% <0%> (-16.67%) 0% <0%> (ø)
...baba/dubbo/remoting/transport/mina/MinaClient.java 57.81% <0%> (-1.57%) 8% <0%> (-1%)
...n/java/com/alibaba/dubbo/common/utils/JVMUtil.java 72.22% <0%> (-1.37%) 13% <0%> (ø)
...ba/dubbo/remoting/transport/netty/NettyHelper.java 31.25% <0%> (-1.01%) 2% <0%> (ø)
...java/com/alibaba/dubbo/common/utils/PojoUtils.java 49.41% <0%> (-0.15%) 63% <0%> (ø)
.../com/alibaba/dubbo/examples/rest/RestProvider.java 0% <0%> (ø) 0% <0%> (ø) ⬇️
... and 17 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 0d002c3...030ebce. Read the comment docs.

@chickenlj chickenlj self-requested a review April 27, 2018 11:23
@chickenlj
Copy link
Copy Markdown
Contributor

Now, i understand DubboInternalLogger's side effect mentioned in #1447, and i've tested this PR works fine.

But i have another question, if we don't attach dubbo prefix before netty logger anymore, why don't we just remove NettyHelper from dubbo? Cause i think maybe name.startsWith("com.alibaba.dubbo.") will never matches.

@beiwei30
Copy link
Copy Markdown
Member Author

why don't we just remove NettyHelper from dubbo? Cause i think maybe name.startsWith("com.alibaba.dubbo.") will never matches.

Good point, I will reconsider

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.

3 participants