Java Messaging Service 1 Introduction.
What is messaging in java. The Jakarta Messaging API formerly Java Message Service or JMS API is a Java application programming interface API for message-oriented middleware. Supporting a variety of typical message exchange patterns and a range of qualities-of-service messaging software frees up application developers to focus on the business value of their code. The Java Message Service JMS was designed to make it easy to develop business applications that asynchronously send and receive business data and events.
Message from one thread to another thread. JMS Java Message Service is an API that provides the facility to create send and read messages. Sender and receiver need not know anything about each other except the destination and message format Email is for people what messaging is for applications.
Suppose we consider an example of producer and consumer likewise what producer will produce the consumer will be able to consume. However the sender and the receiver do not have to be available at the same time in order to communicate. JMS is an abstraction layer for various messaging systems such as TIBCO EMS IBM MQ Active MQ Informatica UM etc.
It is used when threads do not have shared memory and are unable to share monitors or semaphores or any other shared variables to communicate. 1Messaging Approaches in JavaJMS AMQP Kirill AfanasjevJuglv RigaLatvia2. Messaging as a peer to peer facility.
A component sends a message to a destination and the recipient can retrieve the message from the destination. There are two major messaging server models. In the same way that JDBC abstracts access to relational databases and JNDI abstracts access to naming and directory services JMS abstracts access to MOMs.
It enables distributed communication that is loosely coupled. Nor does the receiver need to know. In this post we will see some basics about Java Message Service.