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][TubeMQ] Master start failed with NullPointerException #5567

Closed
1 of 2 tasks
lucaspeng12138 opened this issue Aug 16, 2022 · 2 comments · Fixed by #5569
Closed
1 of 2 tasks

[Bug][TubeMQ] Master start failed with NullPointerException #5567

lucaspeng12138 opened this issue Aug 16, 2022 · 2 comments · Fixed by #5569
Assignees
Labels
Milestone

Comments

@lucaspeng12138
Copy link
Contributor

What happened

Master start failed with NullPointerException.

java.lang.NullPointerException: null
at io.prometheus.client.CollectorRegistry.collectorNames(CollectorRegistry.java:119) ~[simpleclient-0.14.1.jar:?]
at io.prometheus.client.CollectorRegistry.register(CollectorRegistry.java:50) ~[simpleclient-0.14.1.jar:?]
at io.prometheus.client.Collector.register(Collector.java:308) ~[simpleclient-0.14.1.jar:?]
at io.prometheus.client.Collector.register(Collector.java:301) ~[simpleclient-0.14.1.jar:?]
at org.apache.inlong.tubemq.server.master.stats.prometheus.MasterPromMetricService.start(MasterPromMetricService.java:52) ~[tubemq-server-1.3.0-SNAPSHOT.jar:1.3.0-SNAPSHOT]
at org.apache.inlong.tubemq.server.master.TMaster.(TMaster.java:219) ~[tubemq-server-1.3.0-SNAPSHOT.jar:1.3.0-SNAPSHOT]
at org.apache.inlong.tubemq.server.tools.MasterStartup.main(MasterStartup.java:44) ~[tubemq-server-1.3.0-SNAPSHOT.jar:1.3.0-SNAPSHOT]

What you expected to happen

Master start normally.

How to reproduce

File: inlong-tubemq/tubemq-server/src/main/java/org/apache/inlong/tubemq/server/master/stats/prometheus/MasterPromMetricService.java
Caused by start() function, register() will use mfs which is returned from collect(). And when tubemq-master start, collect() will return null. Then NullPointerException happens.

Environment

No response

InLong version

master

InLong Component

InLong TubeMQ

Are you willing to submit PR?

  • Yes, I am willing to submit a PR!

Code of Conduct

@lucaspeng12138 lucaspeng12138 added the type/bug Something is wrong label Aug 16, 2022
@lucaspeng12138
Copy link
Contributor Author

@gosonzhang please have a check, thanks.

@gosonzhang
Copy link
Contributor

@lucaspeng12138, thanks!

This is my fault, sorry, I'll deal with it right now!

@gosonzhang gosonzhang self-assigned this Aug 16, 2022
@gosonzhang gosonzhang changed the title [Bug][TubeMQ] Master start failed with NullPointerException [TubeMQ] Master start failed with NullPointerException Aug 16, 2022
@healchow healchow added this to the 1.3.0 milestone Aug 16, 2022
@healchow healchow changed the title [TubeMQ] Master start failed with NullPointerException [Bug][TubeMQ] Master start failed with NullPointerException Aug 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants