Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

JMS: Listener to Receive Messages From MQ Server ( Request Queue)  RSS feed

 
Vivek Mathur
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

For one integration we are using MQ for messaging (in xml format : that needs to be parsed based on xsd ).

I need to write some listener, who continuously keeps on listing the Request Queue, and as soon as message comes it receives the message (XML) and parse it and save the containing
data in Database.

I tried after some R&D, synchronous communication by creating connection/session and then receiver object to receive message.

Now I want to make This Listener as Asynchronous, that would continuously checking the queue and if any message is there, it should process it.

Can you Please provide some suggestions ?? Or if possible a code snippet would be much helpful.

Regards,
Vivek Mathur
 
Vivek Mathur
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I tried using MDB (Message Driven Beans), as it implements mesagelistener interface and may help in Asynchronous communication with Websphere MQ.
However I am unable to make a connection to QUEUES using JNDI, every time MDB is giving exception as javax.naming.exception ( Queue not bound with queue mangaer "Queue MangerName") and JNDI context wsmq not bound.


Can any one give some light over it ???

Regards,
Vivek Mathur
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!