This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes EJB Certification (SCBCD/OCPJBCD) and the fly likes Topic vs Queue Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Certification » EJB Certification (SCBCD/OCPJBCD)
Bookmark "Topic vs Queue" Watch "Topic vs Queue" New topic
Author

Topic vs Queue

Joe Harry
Ranch Hand

Joined: Sep 26, 2006
Posts: 9345
    
    2

Guys,

What is the difference between a Queue and a Topic in an MDB?. We set this to the destinationType property of the activationConfig. What difference does this make to the MDB? Please help guys!

Thanks in advance.


SCJP 1.4, SCWCD 1.4 - Hints for you, Certified Scrum Master
Did a rm -R / to find out that I lost my entire Linux installation!
Ali Gohar
Ranch Hand

Joined: Mar 18, 2004
Posts: 572
These are two different methods of messaging. Queue is used for point to point messaging means there will be one receiver of the message. There can be more but the message will be received to one of them. It also guarantees delivery of the message, means message will be there in the queue unless it is consumed by someone.

whereas Topic is used for Pub/Sub messaging or broadcasting a message to topic and all the listeners against that topic can consume the message.
Joe Harry
Ranch Hand

Joined: Sep 26, 2006
Posts: 9345
    
    2

Originally posted by Ali Gohar:
These are two different methods of messaging. Queue is used for point to point messaging means there will be one receiver of the message. There can be more but the message will be received to one of them. It also guarantees delivery of the message, means message will be there in the queue unless it is consumed by someone.

whereas Topic is used for Pub/Sub messaging or broadcasting a message to topic and all the listeners against that topic can consume the message.


Thanks!
Ashraf Abu-Aisheh
Ranch Hand

Joined: Apr 17, 2009
Posts: 88
Many thanks Ali Gohar


SCJP 5 - 79%
SCWCD 5 - 100%
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Topic vs Queue
 
Similar Threads
about JMS......Need Help
MDB in connection pool
Transactions in MDB's
Authentication JMS/MDB
Error Deploying Message Bean to Weblogic 8.1