question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

NPE in WARCHdfsBolt on cleanup()

See original GitHub issue

When a (local) topology is killed and no tuples have been passed to the WARCHdfsBolt, the cleanup() will raise a NPE:

68227 [Thread-91-warc-executor[36 36]] INFO  o.a.s.util - Async loop interrupted!
68227 [Thread-89-disruptor-executor[36 36]-send-queue] INFO  o.a.s.util - Async loop interrupted!
68227 [SLOT_1024] INFO  c.d.s.w.GzipHdfsBolt - Cleanup called on bolt
68227 [SLOT_1024] ERROR o.a.s.d.s.Slot - Error when processing event
java.lang.NullPointerException: null
        at com.digitalpebble.stormcrawler.warc.GzipHdfsBolt.cleanup(GzipHdfsBolt.java:187) ~[storm-crawler-fight-2.0-SNAPSHOT.jar:?]
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_181]
        ...
        at org.apache.storm.ProcessSimulator.killProcess(ProcessSimulator.java:67) ~[storm-core-1.2.2.jar:1.2.2]
        at org.apache.storm.daemon.supervisor.LocalContainer.kill(LocalContainer.java:69) ~[storm-core-1.2.2.jar:1.2.2]
        ...

Of course, it’s a minor issue (the topology is shut down anyway) but should either check always initialize the output stream or check whether it is initialized.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
jniochecommented, May 10, 2019

Did you specify the config key for the bolt?

      - name: "withConfigKey"
        args:
          - "warc"
0reactions
jniochecommented, May 10, 2019

Merged, thanks @sebastian-nagel

Read more comments on GitHub >

github_iconTop Results From Across the Web

1.14 Milestone - GitHub
NPE in WARCHdfsBolt on cleanup(), fixes #720 · bug warc. #722 by sebastian-nagel was merged on May 10, 2019.
Read more >
PH39960: J2CA0081E .... CAUGHT EXCEPTION:JAVA.LANG ...
Occasionally "J2CA0081E Method cleanup failed .... Caught exception:java.lang.NullPointerException" may occur when stopping the server.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found