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] SourceWorker#convertRecordToEvent method converts ConnectRecord to CloudEvent throw NPE #4596

Closed
3 tasks done
mxsm opened this issue Dec 2, 2023 · 0 comments · Fixed by #4597
Closed
3 tasks done
Labels
bug Something isn't working

Comments

@mxsm
Copy link
Member

mxsm commented Dec 2, 2023

Search before asking

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

Environment

Windows

EventMesh version

master

What happened

SourceWorker#convertRecordToEvent method may be throw NPE

How to reproduce

when ConnectRecord property is null

Debug logs

Exception in thread "pool-2-thread-1" java.lang.NullPointerException
at org.apache.eventmesh.openconnect.SourceWorker.convertRecordToEvent(SourceWorker.java:247)
at org.apache.eventmesh.openconnect.SourceWorker.startPollAndSend(SourceWorker.java:189)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)

Are you willing to submit PR?

  • Yes I am willing to submit a PR!

Code of Conduct

@mxsm mxsm added the bug Something isn't working label Dec 2, 2023
mxsm added a commit to mxsm/incubator-eventmesh that referenced this issue Dec 2, 2023
@mxsm mxsm changed the title [Bug] ConnectRecord convert to CloudEvent throw NPE [Bug] SourceWorker#convertRecordToEvent method converts ConnectRecord to CloudEvent throw NPE Dec 2, 2023
xwm1992 pushed a commit that referenced this issue Dec 3, 2023
…nnectRecord to CloudEvent throw NPE (#4597)

* [ISSUE #4596]Fix SourceWorker#convertRecordToEvent method converts ConnectRecord  to CloudEvent throw NPE

* fix CloudEventUtil#convertRecordToEvent method converts ConnectRecord to CloudEvent throw NPE
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
1 participant