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 NPE for Dubbo plugin #1260

Merged
merged 36 commits into from Jun 30, 2020
Merged

fix NPE for Dubbo plugin #1260

merged 36 commits into from Jun 30, 2020

Conversation

CoderLan0668
Copy link
Contributor

What does this PR do?

To fix NPE for dubbo plugin.
it might be a problem in dubbo, when the application is both provider and consumer, context.isConsumerSide() is invoking on MonitorFilter exit, NPE will be thrown.

But actually, there is no need to call context.isConsumerSide(), so we can use span != null instead.

CoderLan0668 and others added 30 commits March 5, 2020 16:41
- Reduce allocations by not wrapping callbacks
- Make plugin experimental (opt-in)
- Add @NonnullApi package-level annotations
- Use transaction.type=request, which is consistent with gRPC
- Use activate() instead of activateInScope() to reduce allocations
- Use StringBuilder.append(java.lang.CharSequence, int, int) instead of String.substring(int) to reduce allocations
- Use host:port for destination.service.resource
- Instrument both FutureFilter and MonitorFilter for alibaba dubbo
- Map context ResponseCallback to context because RpcContext is reset already
- Make tests more resilient by waiting for transaction
- Make Apache tests more resilient
- remove sleeps
felixbarny and others added 5 commits June 9, 2020 16:13
was previously used to track classes loaded by the canLoadClass matcher.
But nowadays, it doesn't load classes but only attempts to load the class' resource
# Conflicts:
#	CHANGELOG.asciidoc
#	apm-agent-plugins/apm-dubbo-plugin/pom.xml
#	apm-agent-plugins/apm-dubbo-plugin/src/main/java/co/elastic/apm/agent/dubbo/AbstractAlibabaDubboInstrumentation.java
#	apm-agent-plugins/apm-dubbo-plugin/src/main/java/co/elastic/apm/agent/dubbo/AlibabaResponseFutureInstrumentation.java
#	apm-agent-plugins/apm-dubbo-plugin/src/main/java/co/elastic/apm/agent/dubbo/AlibabaRpcContextInstrumentation.java
#	apm-agent-plugins/apm-dubbo-plugin/src/main/java/co/elastic/apm/agent/dubbo/helper/AsyncCallbackCreatorImpl.java
#	apm-agent-plugins/apm-dubbo-plugin/src/test/java/co/elastic/apm/agent/dubbo/ApacheDubboInstrumentationTest.java
#	docs/configuration.asciidoc
#	elastic-apm-agent/pom.xml
@CoderLan0668 CoderLan0668 changed the title Dubbo fix NPE for Dubbo plugin Jun 30, 2020
@apmmachine
Copy link
Collaborator

apmmachine commented Jun 30, 2020

💚 Build Succeeded

Pipeline View Test View Changes Artifacts preview

Expand to view the summary

Build stats

  • Build Cause: [Started by user Felix Barnsteiner, Replayed #1]

  • Start Time: 2020-06-30T07:17:57.717+0000

  • Duration: 41 min 11 sec

Test stats 🧪

Test Results
Failed 0
Passed 312
Skipped 10
Total 322

@CoderLan0668
Copy link
Contributor Author

@felixbarny sorry, A NPE problem was found in some conditions, i push a commit to fix it

@felixbarny felixbarny merged commit a60ede1 into elastic:master Jun 30, 2020
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.

None yet

3 participants