Win a copy of Beginning Java 17 Fundamentals: Object-Oriented Programming in Java 17 this week in the Java in General forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • Ron McLeod
  • Liutauras Vilda
  • Jeanne Boyarsky
Sheriffs:
  • Junilu Lacar
  • Rob Spoor
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Tim Moores
  • Jesse Silverman
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Piet Souris
  • Frits Walraven

IBM MQ and MDB

 
Ranch Hand
Posts: 375
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Can someone tell me what's the difference between a Message Queue and Message driven bean ? how do they interact with each other ?
 
Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ben
A message queue is a data struture used for holding messages. Think of it like a list where you can push items onto the list and pop items off the list.
A message driven bean is a special type of EJB that is used to listen for messages on a messsage queue , take the message from the queue and perform some processing on the message. All this typically runs as a transaction which allows you to roll the message back on the queue under certain failure scenarios.

You create a queue manager in IBM MQ and create queues associated with this queue manager. Applications write messages to these queues by using API calls like JMS. In you JEE application you will have written a message driven bean , this bean will process messages put to the queue. The bean will be configured to use a javax.jms.QueueconnectionFactory which is a configuration setting in WebSphere that represents connection details to the MQ queue manager and a javax.jms.Queue object which is a configuration in websphere that represents the actual queue associated with a queue manager in MQ.

Brian


 
WHAT is your favorite color? Blue, no yellow, ahhhhhhh! Tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic