Types of Messaging

There are two main ways to send messages: point-to-point and publish-subscribe. A point-to-point messaging application has a single producer (usually) and a single consumer. The producer produces messages while the consumer consumes them. Figure 19.2 illustrates a point-to-point messaging model.

Figure 19.2. A point-to-point messaging system involves a single producer and a single consumer.

A point-to-point system can actually have multiple producers,but usually only a single con sumer. Think of a print server, for instance. Any machine on the network can send a print job to a particular print server. Of course, you can have ...

Get Special Edition Using Java™ 2 Enterprise Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.