It is sometimes needed to do things before starting to process events in an application, like for example loading values from files or databases in Shared Variables, or checking the availability of resources that are critical for the application.
It is also sometimes needed to do things when an application is shutting down, like for example cleaning temporary files in a working directory or sending a JMS message to notify a monitoring solution.
This can be done in BusinessWorks and BusinessWorks Container Edition by using an Activator Process, such Process can be created with the following:
. Go to the Module Descriptor Overview panel of your application and click on the Create Activator Process button
. The Activator Process Creation panel is displayed, selected the target Process Folder and Package, then enter a name for the Process and click Finish
. The Activator Process is now created
. Now you can implement your Activator Process as you need
You can have only one Activator Process per application.
This is generally a good practice to limit the number of activities in an Activator Process and to use Sub Processes if different things have to be done.
In the case you would not need to do something at Startup and nothing at Shutdown you can just leave empty the onShutdown branch (and vice versa).
Additional elements
You can refer to the attached sample project.
Recommended Comments
There are no comments to display.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now