ObjectMessage contains a Serializable java object as it's payload. Thus it allows exchange of Java objects between applications. This in itself mandates that both the applications be Java applications. The consumer of the message must typecast the object received to it's appropriate type. Thus the consumer should before hand know the actual type of the object sent by the sender. Wrong type casting would result in ClassCastException. Moreover the class definition of the object set in the payload should be available on both the machine, the sender as well as the consumer. If the class definition is not available in the consumer machine, an attempt to type cast would result in ClassNotFoundException. Some of the MOMs might support dynamic loading of the desired class over the network, but the JMS specification does not mandate this behavior and would be a value added service if provided by your vendor. And relying on any such vendor specific functionality would hamper the portability of your application. Most of the time the class need to be put in the classpath of both, the sender and the consumer, manually by the developer.
Posted Date:- 2021-11-11 09:29:23
Whats is a subtle difference between a "durable" JMS message and a "persistent" JMS message ?
How to create Transacted session?
What is Client acknowledgement in JMS?
What are Message delivery stages in JMS?
What is the advantage of persistent message delivery compared to nonpersistent delivery?
What is the use of ObjectMessage?
What are the different types of messages available in the JMS API?
Are you aware of any major JMS products available in the market?
For sending messages through JMS, what encryption options are there?
How you can deliver a java message to a non-java client?
Explain the difference between topic and queue?
How does the Application server handle the JMS Connection?
What encryption options are there for sending messages through JMS?
Does Tomcat support JMS (Java Messaging Service)?
Give an example of using the point-to-point model.
How does a typical client perform the communication?
What is the Role of the JMS Provider?
What are the core JMS-related objects required for each JMS-enabled application?
How does the Application server handle the JMS Connection?
What is the role of JMS in enterprise solution development?
What are the core JMS-related objects required for each JMS-enabled application?
Where JMS is used in the e-commerce application?
How to send data in the file to JMS queue in tibco bw?
What is the use of JMS file store?
Explain request-response message exchange pattern.
Explain Message promotion in Solace Message delivery mode.
Can I deliver a Java message to a non-java client?
Explain how JMS works with the J2EE?
What is the difference between Byte Message and Stream Message?
Name some of the other major JMS products available in the market.
Difference between topic and queue in JMS.
Difference between Point to Point and Publish/Subscribe models in JMS.
What are the advantages of JMS?
Which JMS Provider have you worked with? Like IBM's WMQ, Apache Active MQ, Sonic MQ, etc
What is JMS Selector? How does it work? Any example of Using JMS Selector?
Does JMS Session object is thread-safe? Can we share JMS Session among multiple threads?
Explain Asynchronous messaging in JMS.
Explain Synchronous messaging in JMS.
How JMS (Java messaging service) is different from RPC (Remote Procedure call)?