In this exercise, you will learn how to use work with the EJB Timer Service. The examples in this chapter match the modifications made to the Ship EJB to enable Timers. This exercise builds off the code within Exercise 12.1, so initialization and deployment should be around the same.
You need to clean and refresh the database. To do this, shutdown
JBoss if you have it running and run
clean.db. Then restart JBoss.
Perform the following steps:
Open a command prompt or shell terminal and change to the
ex13_1 directory created by the extraction
JBOSS_HOME environment variables to point to where
your JDK and JBoss 4.0 are installed. Examples:
ant to your execution path. Ant is the build
The exercise uses a JMS Topic. Deploy the topic using the following Ant target.
$ ant make-topic
Build the EJBs used in this example.
You will see
titan.jar copied to the JBoss
deploy directory and redeployed by the
Initialize the database.You will see a bunch of entity beans being created.
$ ant createdb
The scheduleMaintenance, ...