Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

jms server interoperability (activemq & weblogic)

 
Matt Zollinhofer
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
After a servlet is hit, I need to send a JMS message to two separate JMS servers (an ActiveMQ queue and a Weblogic queue). I think I'm running into classloader issues with the two separate jars: weblogic.jar and the Activemq-all-5.0.0.jar.

It seems to be conflicting because both of the contain the javax.jms.* package, in particular the QueueConnectionFactory.

I can send messages to each of them if I remove the other from the equation without a problem, but when I put the both in the war so the servlet can try to do both it fails.

Is there a standard approach to this? Are there standard javax.jms.* jars that come from Sun that I should be using? If they use standard jms.jar how do I handle connecting to weblogic and activemq?

Any help is appreciated,
Matt
[ February 18, 2008: Message edited by: Matt Zollinhofer ]
 
Abhinav Srivastava
Ranch Hand
Posts: 354
Eclipse IDE Java Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
do both jars implement the same version of j2ee/jms?
 
Matt Zollinhofer
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
sorry for the slow response, I was having trouble getting logged into javaranch for a while there.

I'm not exactly sure. They are implementing the same classes at least by name.

Is it not at all common for one class to try to send messages to two different JMS queues? Has anyone done that?
 
Cedric Neve
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

We are sending messages to JBoss, Weblogic and ActiveMQ from the same application. In you case, I suppose you should only embed the activeMQ-core.jar in order to avoid the conflicting JMS implementations.

Best of luck,
Cedric
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic