camel-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Netherton (JIRA)" <>
Subject [jira] [Created] (CAMEL-11465) NPE caused by IrcMessage
Date Tue, 27 Jun 2017 15:59:00 GMT
James Netherton created CAMEL-11465:

             Summary: NPE caused by IrcMessage
                 Key: CAMEL-11465
             Project: Camel
          Issue Type: Bug
          Components: camel-irc
            Reporter: James Netherton

The {{IrcEndpoint}} has a number of methods like {{createOnPrivmsgExchange}}, {{createOnNickExchange}}
etc, where an instance of {{IrcMessage}} is created. When the constructor is called, it results

16:49:55,426 ERROR [stderr] (Thread-97) Exception in thread "Thread-97" java.lang.NullPointerException
16:49:55,427 ERROR [stderr] (Thread-97) 	at org.apache.camel.impl.MessageSupport.setBody(
16:49:55,427 ERROR [stderr] (Thread-97) 	at org.apache.camel.component.irc.IrcMessage.<init>(
16:49:55,427 ERROR [stderr] (Thread-97) 	at org.apache.camel.component.irc.IrcEndpoint.createOnPrivmsgExchange(
16:49:55,427 ERROR [stderr] (Thread-97) 	at org.apache.camel.component.irc.IrcConsumer$FilteredIRCEventAdapter.onPrivmsg(
16:49:55,427 ERROR [stderr] (Thread-97) 	at org.schwering.irc.lib.IRCConnection.get(
16:49:55,428 ERROR [stderr] (Thread-97) 	at

Seems there's now a dependency on the CamelContext in [MessageSupport.setBody|]
and the {{IrcMessage}} constructor calls {{setBody}} before the CamelContext has been provided
to it (it's currently set after the constructor is called).

This message was sent by Atlassian JIRA

View raw message