- JMS Tutorial
- JMS - Home
- JMS - Introduction
- JMS - Overview of JMS API
- JMS - Installation
- JMS - API Architecture
- JMS - Point-To-Point Message
- JMS - Publish/Subscribe Message
- JMS - Programming Model
- JMS - Message Components
- JMS - Enterprise Messaging Systems
- JMS - JMS API in Java EE Applications
- JMS Useful Resources
- JMS - Quick Guide
- JMS - Useful Resources
- JMS - Discussion
JMS - Message Components
Description
JMS message communicates with JMS clients by using three JMS components −
- Message Header
- Message Properties
- Message Body
Message Header
The JMS message header includes following fields, which are used by clients and providers to indicate and send messages.
- JMSDestination
- JMSDeliveryMode
- JMSTimestamp
- JMSMessageID
- JMSReplyTo
- JMSCorrelationID
- JMSReplyTo
- JMSRedelivered
- JMSType
- JMSExpiration
- JMSPriority
Message Properties
Properties can be created and set for the messages by using the custom name value pairs. The message properties are used with other messaging systems, to create message selectors and for supporting filtering messages.
Message Body
The JMS API provides following message body formats, which are used to send and receive the information in various forms −
Text message − It defines the text message by using the javax.jms.TextMessage interface.
Object message − It defines the Java object by using the javax.jms.ObjectMessage interface.
Bytes message − It specifies the binary data by using the javax.jms.BytesMessage interface.
Stream message − It specifies the Java's primitive values (such as int, char, float etc) by using the javax.jms.StreamMessage interface.
Map message − It specifies the key/value pair by using the javax.jms.MapMessage interface.
To Continue Learning Please Login
Login with Google