JMS Event Listener with RabbitMQ

Support questions related to CloverETL Server

sshrestha
Posts: 2
Joined: Tue Jul 11, 2017 6:50 pm

JMS Event Listener with RabbitMQ

Postby sshrestha » Tue Jul 11, 2017 8:33 pm

I am trying to create a JMS Event Listener using RabbitMQ. But it fails to activate the Event Listener with the following messages:

Code: Select all

Listener has been updated
error   Some library classes missing. Check whether the third party libraries are on the classpath.
No definition for the class with the specified name can be found: javax/jms/JMSException
 Class with the specified name cannot be found: javax.jms.JMSException
                       
java.lang.NoClassDefFoundError: javax/jms/JMSException
        at com.cloveretl.server.events.b.f.aC(Main:100)
        at com.cloveretl.server.events.b.f.init(Main:110)
        at com.cloveretl.server.events.listeners.livecycle.NodeDependentEventListenerLivecycleAware.a(Main:284)
        at com.cloveretl.server.events.listeners.livecycle.NodeDependentEventListenerLivecycleAware.a(Main:57)
        at com.cloveretl.server.events.listeners.livecycle.NodeDependentEventListenerLivecycleAware$1.call(Main:208)
        at com.cloveretl.server.events.listeners.livecycle.NodeDependentEventListenerLivecycleAware$1.call(Main:203)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.ClassNotFoundException: javax.jms.JMSException
        at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1285)
        at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1119)
        ... 10 more

                                                               
Close Detail
error   The listener failed to activate
No definition for the class with the specified name can be found: javax/jms/JMSException
 Class with the specified name cannot be found: javax.jms.JMSException
                       
java.lang.NoClassDefFoundError: javax/jms/JMSException
        at com.cloveretl.server.events.b.f.aC(Main:100)
        at com.cloveretl.server.events.b.f.destroy(Main:115)
        at com.cloveretl.server.events.listeners.livecycle.NodeDependentEventListenerLivecycleAware.a(Main:310)
        at com.cloveretl.server.events.listeners.livecycle.NodeDependentEventListenerLivecycleAware.a(Main:57)
        at com.cloveretl.server.events.listeners.livecycle.NodeDependentEventListenerLivecycleAware$1.call(Main:208)
        at com.cloveretl.server.events.listeners.livecycle.NodeDependentEventListenerLivecycleAware$1.call(Main:203)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.ClassNotFoundException: javax.jms.JMSException
        at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1285)
        at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1119)
        ... 10 more


We have installed the required plugin (https://www.rabbitmq.com/jms-client.html) so that RabbitMQ can support JMS Queue.
We also installed Java JMS Client for RabbitMQ (https://github.com/rabbitmq/rabbitmq-jms-client).

Could you please tell us what this error is about and how we should go about fixing this problem?

vazquezrosariop
Posts: 95
Joined: Mon Feb 29, 2016 5:33 pm

Re: JMS Event Listener with RabbitMQ

Postby vazquezrosariop » Wed Jul 12, 2017 8:26 pm

Hi sshrestha,

From the stack trace you included, it appears that the RabbitMQ Java client library is not specified in the application server that CloverETL Server is stored. If so, please download the rabbitmq.jar file and add it to the following path <TOMACAT_HOME>/lib folder and restart the server.
---
Pedro Vazquez Rosario
CloverCARE Support
CloverETL | Rapid Data Integration

Visit us online at http://www.cloveretl.com
How to speed up communication with CloverCARE support

sshrestha
Posts: 2
Joined: Tue Jul 11, 2017 6:50 pm

Re: JMS Event Listener with RabbitMQ

Postby sshrestha » Thu Jul 13, 2017 5:44 pm

vazquezrosariop wrote:From the stack trace you included, it appears that the RabbitMQ Java client library is not specified in the application server that CloverETL Server is stored. If so, please download the rabbitmq.jar file and add it to the following path <TOMACAT_HOME>/lib folder and restart the server.


Thank you Pedro.

We did go through this step. Maybe it was the wrong jar file. Do you think you could point us to the correct link for the jar file?

vazquezrosariop
Posts: 95
Joined: Mon Feb 29, 2016 5:33 pm

Re: JMS Event Listener with RabbitMQ

Postby vazquezrosariop » Wed Jul 26, 2017 2:48 pm

I have taken the liberty of attaching the example RabbitMQ graph, please look through it and let me know if you have any questions. Some notes about the graph:

  • RabbitMQ Reader and RabbitMQ Ack are both CustomJava components, and please look over the code in the trans folder.
  • Once the RabbitMQ Ack component is triggered the message will acknowledge, I would recommend adding writer to save the message you are pulling.

RabbitMQ.zip
(436.11 KiB) Downloaded 4 times
---
Pedro Vazquez Rosario
CloverCARE Support
CloverETL | Rapid Data Integration

Visit us online at http://www.cloveretl.com
How to speed up communication with CloverCARE support


cron