
Contributor
2012-06-01
08:41 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
JMS messaging queues
Can you please provide a tutorial for how to use tMOM in a talend job to listen for messages on a jms queue. Also, provide a short best practice for this type of setup(should I use a topic or a gueue). The biggest problem I am having is setting up a gueue for multiple listeners instead of round robin and is this a good approach or not.
236 Views
4 Replies

Anonymous
Not applicable
2012-06-08
12:27 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Peter
This sounds like the primary confusion concerns queues or topics. A queue by definition will deliver a message to exactly one consumer. There can be multiple competing consumers on the queue to effectively load balance the queue, but the message will only be delivered to exactly one of them. For example, if have queue Q with three consumers C1, C2, and C3, and I post messages m1, m2, m3, and m4 to Q, then m1 will be processed by exactly once of C1, C2, or C3, and the same is true of the other messages as well. There is no policy for deterministically controlling which consumer will get which message.
I am guessing from your description that for your "multiple" listeners case you would prefer to use a Topic. Topics, in contrast to queues, use a publish-subscribe metaphor so that every message is delivered to every current subscriber. If you want the ability for a subscriber to be temporarily disconnected, then you can use durable subscribers.
Note that from a load-balancing and fault tolerance perspective durable consumers are not ideal. See http://activemq.apache.org/nms/activemq-virtual-destinations.html for a discussion.
See the tMOM component in the Reference Guide for details regarding using the tMOM conmponent. Note that you will need to have an ActiveMQ broker instance running for the tMOM component to connect to.
This sounds like the primary confusion concerns queues or topics. A queue by definition will deliver a message to exactly one consumer. There can be multiple competing consumers on the queue to effectively load balance the queue, but the message will only be delivered to exactly one of them. For example, if have queue Q with three consumers C1, C2, and C3, and I post messages m1, m2, m3, and m4 to Q, then m1 will be processed by exactly once of C1, C2, or C3, and the same is true of the other messages as well. There is no policy for deterministically controlling which consumer will get which message.
I am guessing from your description that for your "multiple" listeners case you would prefer to use a Topic. Topics, in contrast to queues, use a publish-subscribe metaphor so that every message is delivered to every current subscriber. If you want the ability for a subscriber to be temporarily disconnected, then you can use durable subscribers.
Note that from a load-balancing and fault tolerance perspective durable consumers are not ideal. See http://activemq.apache.org/nms/activemq-virtual-destinations.html for a discussion.
See the tMOM component in the Reference Guide for details regarding using the tMOM conmponent. Note that you will need to have an ActiveMQ broker instance running for the tMOM component to connect to.
236 Views

Anonymous
Not applicable
2012-06-08
01:18 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have posted an example of using tMOMconsumer in this related post
http://www.talendforge.org/forum/viewtopic.php?pid=87218#p87218 .
236 Views

Anonymous
Not applicable
2013-10-08
04:42 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am using Topic is a non clustered environment. How can i configure tMOMInput as a durable subscriber. I shall really appreciate your help.
236 Views

Anonymous
Not applicable
2014-06-15
09:59 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I am using Topic with JMS mediation component. How can i configure tMOMInput as a durable subscriber.
Any Idea ?
I am using Topic with JMS mediation component. How can i configure tMOMInput as a durable subscriber.
Any Idea ?
236 Views
