O'Reilly - Java Message Service
O'Reilly - Java Message Service
O'Reilly - Java Message Service
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
<strong>Java</strong> <strong>Message</strong> <strong>Service</strong><br />
to naming and directory services, JMS abstracts access to MOMs. Using JMS, a messaging<br />
application's messaging clients are portable across MOM products.<br />
The creation of JMS was an industry effort. <strong>Java</strong>Soft took the lead on the spec and worked<br />
very closely with the messaging vendors throughout the process. The initial objective was<br />
to provide a <strong>Java</strong> API for connectivity to MOM systems. However, this changed to the<br />
wider objective of supporting messaging as a first-class <strong>Java</strong> distributed computing<br />
paradigm equally with Remote Procedure Call (RPC) based systems like CORBA and<br />
Enterprise <strong>Java</strong>Beans:<br />
There were a number of MOM vendors that participated in the creation of<br />
JMS. It was an industry effort rather than a Sun effort. Sun was the spec<br />
lead and did shepherd the work but it would not have been successful<br />
without the direct involvement of the messaging vendors. Although our<br />
original objective was to provide a <strong>Java</strong> API for connectivity to MOM<br />
systems, this changed over the course of the work to a broader objective of<br />
supporting messaging as a first class <strong>Java</strong> distributed computing paradigm<br />
on equal footing with RPC.<br />
- Mark Hapner, JMS spec lead, Sun Microsystems<br />
The result is a best-of-breed, robust specification that includes a rich set of message<br />
delivery semantics, combined with a simple yet flexible API for incorporating messaging<br />
into applications. The intent was that in addition to new vendors, existing messaging<br />
vendors would support the JMS API.<br />
1.2.1 JMS Messaging Models: Publish-and-Subscribe and Point-to-Point<br />
JMS provides for two types of messaging models, publish-and-subscribe and point-topoint<br />
queuing. The JMS specification refers to these as messaging domains. In JMS<br />
terminology, publish-and-subscribe and point-to-point are frequently shortened to pub/sub<br />
and p2p (or PTP), respectively. This book uses both the long and short forms throughout.<br />
In the simplest sense, publish-and-subscribe is intended for a one-to-many broadcast of<br />
messages, while point-to-point is intended for one-to-one delivery of messages (see Figure<br />
1.4).<br />
Figure 1.4. JMS messaging domains<br />
10