As discussed above, a critical architectural feature of JMS is that it decouples the objects that send messages from those that receive messages. This architecture contrasts, for example, with the JavaBean event model, where an event listener must register with the object that fires the event. In the JMS messaging model, objects that send messages (message producers) and objects that receive messages (message consumers) do not need to be aware of each other, because a producer does not send messages directly to a consumer.

Instead, a JMS message producer sends a message to a destination, where it is retrieved by one or more message consumers. JMS defines two types of destinations, corresponding to two basic forms of messaging:

Copyright © 1997, 2013 Oracle and/or its affiliates. All rights reserved. Legal Notices