There are two types of startup beans: application startup beans and Module startup beans.
A module startup bean is a session bean that is loaded when an EJB Jar file starts. Module startup beans enable Java 2 Platform Enterprise Edition (J2EE) applications to run business logic automatically, whenever an EJB module starts or stops normally. An application startup bean is a session bean that is loaded when an application starts. Application startup beans enable Java 2 Platform Enterprise Edition (J2EE) applications to run business logic automatically, whenever an application starts or stops normally.
Startup beans are especially useful when used with asynchronous bean features. For example, a startup bean might create an alarm object that uses the Java Message Service (JMS) to periodically publish heartbeat messages on a well-known topic. This enables clients or other server applications to determine whether the application is available. Refer to the Enabling an application to wait for a messaging engine to start article if you are using the default JMS provider.
In this information ... | IBM Redbooks, demos, education, and more(Index) |