JavaTM Message Service Tutorial


The JavaTM Message Service (JMS) Tutorial is provided as a companion to the Java 2, Enterprise Edition (J2EETM) SDK, version 1.3.1.

The J2EE 1.3.1 tutorial has the following goals:

  • To introduce the JMS API to new users, with simple JMS client program examples
  • To show how to use the JMS API within the J2EE platform, with examples showing how to
    • Consume messages asynchronously with a message-driven bean
    • Produce messages from an application client
    • Produce messages from a session bean
    • Access an entity bean from a message-driven bean
    • Produce and consume messages on more than one system

The tutorial assumes that you are familiar with the Java programming language and that you have some experience with the J2EE platform.

To run the examples, you must first install the J2EE SDK version 1.3.1. You should first install the required version of the Java 2 SDK, Standard Edition, if it is not already installed.

You may read the tutorial online:

JMS Tutorial

Alternatively, you may download the Tutorial and use it on your own system. The download bundle is available in either zip or PDF format.

The zip file contains the HTML version of the tutorial and the source code for the examples. Unzipping the file creates a directory called jms_tutorial, in which the tutorial is installed. To access the tutorial, open the jms_tutorial/index.html file in your web browser.

The PDF file provides you with a convenient way to print the tutorial. To view and print the PDF file, you must have installed Adobe Acrobat Reader on your system. Adobe Acrobat Reader is free and available from the Adobe Systems website.

The list of Frequently Asked Questions provides some troubleshooting information.

This Tutorial contains information on the 1.3.1 version of the Java 2 Platform, Enterprise Edition.

Copyright © 2002 Sun Microsystems, Inc. All rights reserved.