![]() |
|
Application hooks are used to synchronize with application lifecycle events. Each application can have it's own hook. The class-name attribute is the class which implements the application hook interface. The async parameter specifies whether or not to call the hook methods in a separate thread.
com.pramati.services.j2ee.spi.ApplicationStateListener for more details.
<application-hooks> <!-- application-hook app-name="appName" async="true" class-name="className"/--> </application-hooks>
Server Application Hooks provide a listener mechanism for lifecycle events for specific applications. An application hook defines a callback interface that can be implemented by application developers to receive callbacks at certain points in their application lifecycle. Such lifecycle events might include the following:
The application hook can use application classes in all these methods except the applicationRemoved() since the methods are always called in the context of the application classloader. In case the application hook class uses any application classes, the hook class should be placed in such a location (with the application/outside it) that the application classes are visible to it.
Note: For further information on the classloading hierarchy and any known caveats, read Classloader Architecture in Pramati Server.
| © Pramati Technologies 2007 | Runs on Pramati Server | Feedback | Legal |