JMS, an asynchronous messaging system has a modes know as point to point and pub/sub. Point to point could be be RMI, a synchronous protocol. Point to point is not tied to either synchronous or asynchronous.
Rufus, I beg to differ. Middleware Architectures follow one of two forms - Synchronous Communication and Asynchronous Communication. Synchronous Communication is used typically when a client is requesting a server to do some processing and is waiting for the response before proceeding further. The best example for Synchronous communication is RPC based mechanisms. Examples of RPC based mechanisms are - IIOP, RMI/JRMP, RMI/IIOP. (Note: EJB 2.0 supports a message listener in the new bean type and CORBA also has event listener capabilities, but generally speaking, remote method invocation is the normal purpose.) Excellent example is Credit Card validation. Without that you do not want to continue with the transaction. Asynchronous communication is used when: 1. you need time transparency - do not want sub-system dependencies (check durable queues / subscribers for more info)i.e., The message producer does not need to wait for an ack before proceeding further. 2. Location transparency: In a stock quote application, the publisher has no need to know who the subscribers are and where they are. (Note: With EJB using JNDI and CORBA using COS naming e.t.c., location transparency is achieved in RPC too, but the scope is a little different here) In many JMS books, they talk about using JMS (MOM messaging) synchronously. Please note that they only simulate synchronous behavior. This is done via two asynchronous messages used back-to-back. This is not to be confused with RPC behavior. They talk about P2P specifically because that is the messaging model intended for one-to-one use. (Pub / Sub is supposed to be used as a Broadcast mechanism, so ack has no relevance here.) HTH.
Sanjay Raghavan<br />SCJP2, SCEA-J2EE<br />Moderator - <a href="http://groups.yahoo.com/group/scea_prep" target="_blank" rel="nofollow">SCEA PREP</a><br />Co-Author - <a href="http://www.whizlabs.com/scea/scea.html" target="_blank" rel="nofollow">SCEA@Whiz</a><br /><i>Where did you sip your Java Today?</i>
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop