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

[Bug] Two NPE problems with Tcp Protocol Resolver #1022

Closed
2 tasks done
mytang0 opened this issue Jul 14, 2022 · 0 comments
Closed
2 tasks done

[Bug] Two NPE problems with Tcp Protocol Resolver #1022

mytang0 opened this issue Jul 14, 2022 · 0 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@mytang0
Copy link
Member

mytang0 commented Jul 14, 2022

Search before asking

  • I had searched in the issues and found no similar issues.

Environment

Linux

EventMesh version

master

What happened

When the property 'subsystem' of UserAgent is null

How to reproduce

  1. Explicitly throw the 'key' of the exception to facilitate problem location.
  2. Fix NPE

Debug logs

Location:

java.lang.NullPointerException: null
at org.apache.eventmesh.protocol.meshmessage.resolver.tcp.TcpMessageProtocolResolver.buildEvent(TcpMessageProtocolResolver.java:82)
at org.apache.eventmesh.protocol.meshmessage.MeshMessageProtocolAdaptor.deserializeTcpProtocol(MeshMessageProtocolAdaptor.java:81)
at org.apache.eventmesh.protocol.meshmessage.MeshMessageProtocolAdaptor.toCloudEvent(MeshMessageProtocolAdaptor.java:59)
at org.apache.eventmesh.runtime.core.protocol.tcp.client.task.MessageTransferTask.run(MessageTransferTask.java:110)

and location:

upload trace fail when finishSpanWithException
java.lang.NullPointerException: null
at org.apache.eventmesh.runtime.trace.Trace.addTraceInfoToSpan(Trace.java:104)
at org.apache.eventmesh.runtime.trace.TraceUtils.finishSpanWithException(TraceUtils.java:110)
at org.apache.eventmesh.runtime.core.protocol.tcp.client.task.MessageTransferTask.run(MessageTransferTask.java:184)

Are you willing to submit PR?

  • Yes I am willing to submit a PR!
@mytang0 mytang0 added the bug Something isn't working label Jul 14, 2022
xwm1992 added a commit that referenced this issue Aug 4, 2022
[ISSUE #1022] Two NPE problems fixes for Tcp Protocol Resolver
close #1022
@xwm1992 xwm1992 added this to the 1.6.0 milestone Aug 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants