Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

How does JMS pass messages?  RSS feed

Chris Johnston
Ranch Hand
Posts: 85
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Simple question: how does JMS pass messages, by reference or by value?

If I have two topics, topic1 and topic2, with messages-driven beans registered with each topic:

topic1 --> mdb1
topic2 --> mdb2

I have a message that consists of some data, say it is a 20KB jpeg file encapsulated within an object, data1, that I then put inside a message, say message1. I then want to pass that message from topic1 to topic2 using the mdbs.

How does JMS handle passing the data? Does it simply pass the message containing references to the embedded object (pass by reference) or does it pass all the data from topic to topic (pass by value)?

What happens when I increase the size of the contained object (the jpeg) to 1MB in size? How does this affect JMS?

I would think that if it used pass by reference, then the size of the enclosed data does not matter. Whereas, if it is pass by value, then the larger the objects being passed, the slower JMS would work.

This is all happening within a single app server.

Any ideas?
[ June 23, 2005: Message edited by: Chris Johnston ]
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!