From the course: Spring: Messaging with JMS
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Spring JMS message converters - Spring Tutorial
From the course: Spring: Messaging with JMS
Spring JMS message converters
- [Instructor] You might be wondering, what is a Spring JMS message converter? JMS provides for some basic messaging types like Streams, Map, Text, Object, and Bytes. These JMS message types for the most part form the foundation of all other message types that exist. For example, a JSON or XML message could be easily sent as TextMessages. Images or sound or music files could be sent as ByteMessages. Spring provides out of the box, a default conversion through its SimpleMessageConverter. The SimpleMessageConverter is able to handle TextMessages, BytesMessages, MapMessages, and ObjectMessages. The only base JMS message type that it does not handle is the StreamMessages. We've used JmsTemplate.convertAndSend. The default conversion strategy used with converAndSend is the SimpleMessageConverter. This is the case, unless we specify a different converter in our configuration as a Spring bean. Spring additionally provides some other message converters for use. But, we would have to specify…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
(Locked)
Spring JMS message converters3m 5s
-
(Locked)
Project work for JMS message converter4m 49s
-
Example code using Spring JMS converter7m 41s
-
(Locked)
Demonstrate app with changes6m 57s
-
(Locked)
Message converter for XML messages7m 58s
-
(Locked)
Create custom message listener with Spring5m 10s
-
(Locked)
Register custom message listener with Spring3m 49s
-
(Locked)
-
-
-