Support Questions
Find answers, ask questions, and share your expertise

Error Using ConsumeJMS with HornetQ

Highlighted

Error Using ConsumeJMS with HornetQ

New Contributor

I am trying to connect to HornetQ from NiFi using the ConsumeJMS processor, but am getting the following error:

javax.jms.JMSException: Failed to create session factory
2018-06-04 13:20:17,878 WARN [Timer-Driven Process Thread-3] o.a.n.controller.tasks.ConnectableTask Administratively Yielding ConsumeJMS[id=bc5d94f1-0163-1000-d28b-19df13421743] due to uncaught Exception: org.springframework.jms.UncategorizedJmsException: Uncategorized exception occured during JMS processing; nested exception is javax.jms.JMSException: Failed to create session factory
org.springframework.jms.UncategorizedJmsException: Uncategorized exception occured during JMS processing; nested exception is javax.jms.JMSException: Failed to create session factory
	at org.springframework.jms.support.JmsUtils.convertJmsAccessException(JmsUtils.java:316)
	at org.springframework.jms.support.JmsAccessor.convertJmsAccessException(JmsAccessor.java:169)
	at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:497)
	at org.apache.nifi.jms.processors.JMSConsumer.consume(JMSConsumer.java:85)
	at org.apache.nifi.jms.processors.ConsumeJMS.rendezvousWithJms(ConsumeJMS.java:181)
	at org.apache.nifi.jms.processors.ConsumeJMS.rendezvousWithJms(ConsumeJMS.java:59)
	at org.apache.nifi.jms.processors.AbstractJMSProcessor.onTrigger(AbstractJMSProcessor.java:157)
	at org.apache.nifi.jms.processors.ConsumeJMS.onTrigger(ConsumeJMS.java:59)
	at org.apache.nifi.processor.AbstractProcessor.onTrigger(AbstractProcessor.java:27)
	at org.apache.nifi.controller.StandardProcessorNode.onTrigger(StandardProcessorNode.java:1147)
	at org.apache.nifi.controller.tasks.ConnectableTask.invoke(ConnectableTask.java:175)
	at org.apache.nifi.controller.scheduling.TimerDrivenSchedulingAgent$1.run(TimerDrivenSchedulingAgent.java:117)
	at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
	at java.util.concurrent.FutureTask.runAndReset(Unknown Source)
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(Unknown Source)
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
	at java.lang.Thread.run(Unknown Source)
Caused by: javax.jms.JMSException: Failed to create session factory
	at org.hornetq.jms.client.HornetQConnectionFactory.createConnectionInternal(HornetQConnectionFactory.java:587)
	at org.hornetq.jms.client.HornetQConnectionFactory.createConnection(HornetQConnectionFactory.java:107)
	at org.springframework.jms.connection.UserCredentialsConnectionFactoryAdapter.doCreateConnection(UserCredentialsConnectionFactoryAdapter.java:178)
	at org.springframework.jms.connection.UserCredentialsConnectionFactoryAdapter.createConnection(UserCredentialsConnectionFactoryAdapter.java:152)
	at org.springframework.jms.connection.SingleConnectionFactory.doCreateConnection(SingleConnectionFactory.java:365)
	at org.springframework.jms.connection.SingleConnectionFactory.initConnection(SingleConnectionFactory.java:305)
	at org.springframework.jms.connection.SingleConnectionFactory.getConnection(SingleConnectionFactory.java:283)
	at org.springframework.jms.connection.SingleConnectionFactory.createConnection(SingleConnectionFactory.java:224)
	at org.springframework.jms.support.JmsAccessor.createConnection(JmsAccessor.java:180)
	at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:484)
	... 16 common frames omitted
Caused by: java.lang.NullPointerException: null
	at org.hornetq.jms.client.HornetQConnectionFactory.createConnectionInternal(HornetQConnectionFactory.java:583)
	... 25 common frames omitted

Both HornetQ and NiFi are running locally on my Windows 10 laptop. I am able to connect to HornetQ and send and receive messages from a test Java program: client.zip..

My NiFi Controller Service Details and Processor settings are attached as screen shots.

Any help would be much appreciated

--

HornetQ Server version 2.5.0.SNAPSHOT (Wild Hornet, 124)

Apache NiFi 1.6.0


76575csd.pngcsd.png
1 REPLY 1
Highlighted

Re: Error Using ConsumeJMS with HornetQ

New Contributor

I'm bumping this thread.

Has anybody been able to get NiFi to connect with HornetQ?