| The JOnAS Alarm Demo |  |

## Goal of this demo

This little demo intends to show how you can use JOnAS, Tomcat or Jetty, and Joram together to get a complete application using EJBs, servlets, html, JSPs, and message driven beans.

## Running this demo

When you click to access this demo, your web browser should open a dialog box asking you a user ID and a password. Enter as login/password tomcat/tomcat or jetty/jetty.

Click Here to Start the Demo

Notice that the first time, Tomcat or Jetty has to compile each JSP and this may take several seconds.

## Description of the different parts

AlarmGenerator | AlarmGenerator is a servlet that generates alarms by publishing messages on a topic. Once the JOnAS Server is running, this servlet may be used to feed the Message Driven Bean listening on the topic. Click Here to Generate new Alarms
Session bean View | A Session bean is used to provide a remote access to the Alarm Service. Each user will create its own session that will be reached from JSP pages or servlets.
Entity Bean AlarmRecord | When a new alarm type is received, an entity bean is created. If the Alarm is already known, its count is incremented only.
Message Driven Bean | JMS is used to access asynchronously to the service. A Message Driven Bean is used to collect Alarm sent by AlarmGenerator. It will then inform the AlarmManager that will process it.

## Architecture