Win a copy of JDBC Workbook this week in the JDBC and Relational Databases forum
or A Day in Code in the A Day in Code 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 all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
  • Ron McLeod
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Frits Walraven
  • Tim Holloway
  • Carey Brown
  • Piet Souris
  • salvin francis
  • fred rosenberger

Messaging PointTopoint and Publish-Subscribe

Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Members,

I was reviewing Messaging from IBM document, and they said regarding point-to-point Model that the message is sent to queue and the receiver get the message from there, and they could be many senders, but just one receiver consumes the message from the queue.
For Publish/Subscribers, they said the message goes to a Topic, which mean all subscribers to that Topic will get the message also many senders can send message to that topic (many Senders and many Receivers)

In contrast, I had a question from Whizlab test, where they said
Public/Subscrib Messaging = one Sender and Many receivers
Point-to-point messaging = one Sender and one Receiver.
Can some one help me to clarify this please, I really need the answer as soon as possible ...

Thank you so much for you help and response

Best Regards,
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Rania,

both are right from their point of view.

I think IBM's view is a bit misleading and mixes up the message itself and the mediation (queue/topic).

Focussing the view on a single message:
- One single message is always emitted by one sender (no doubt about that, I think).
- In P2P one message is always consumed by exactly one receiver.
- In Pub/Sub one message goes to many receivers (all that are subscribed).
So that's what Whizlabs is talking about.

If you focus on the mediation, you end up with IMB's view:
- Queue: Many senders sending, but each message is consumed by only one receiver.
- Topic: Many senders sending, each message gets distributed to the subscribers.

I think Whizlabs's view is a bit more to the point, because IBM doesn't consider, that also in P2P it is possible, that there is more than one receiver listening to the queue (done that) - but as soon as one receiver has taken a message from the queue, it is consumed.

Hope that helps,
rania ferrag
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks a lot Frank for the prompt answer, I think I got the idea...

Best Regards,

And inside of my fortune cookie was this tiny ad:
Devious Experiments for a Truly Passive Greenhouse!
    Bookmark Topic Watch Topic
  • New Topic