RuleApp execution code generators
To call a ruleset on Rule Execution Server, you must write execution code to locate a deployed RuleApp that contains the ruleset on an application server. Decision Server includes a set of generators for you to create execution code, together with the necessary configuration parameters and resources for a new client project. You can use the code generators to create ruleset execution code for your Eclipse client projects.
- In Rule Explorer, right-click your rule project and select .
- In the New Project window, select one of the following wizards:
- Client Project for RuleApps
| Wizard | Use with | Description | Generator |
|---|---|---|---|
| Client Project for Decision Service |
You associate the client project with a deployment configuration. |
Generates the necessary Java™ code to invoke a particular RuleApp based on a deployment configuration. The deployment configuration defines the operations or rulesets to use and identifies the target servers to connect to. The client project is generated in only one Rule Execution Server on Java SE target (one folder on the file system). XOM deployment is not supported for Java SE targets, though it can be configured by using the class path. |
Java Project for Rule Execution Server on Java SE: Generates a simple Java project with a main method that demonstrates a ruleset invocation. |
| JUnit Project for Rule Execution Server on Java SE: Generates, for each ruleset, a JUnit test case with one test that can be duplicated to test with another set of parameters. |
Because Operational Decision Manager is divided into modules (executionserver, studio, decisioncenter), each module contains its own lib directory.
You need to define executionserver.home before importing
classpath-executionserver.xml, and engine.lib.dir for
classpath-engine.xml. The executionserver.home value is
<InstallDir>/executionserver and the
engine.lib.dir value is
<InstallDir>/executionserver/lib. It is not necessary
to define this property when importing classpath-executionserver.xml.
The sample File ruleset execution shows how to run a ruleset that is deployed on the file system. It provides an example of an Ant build file that uses the classpath-executionserver.xml file to package an application executing rules in <InstallDir>/executionserver/samples/j2serulesession/build.xml.
- For these generators to run, you must have Rule Execution Server correctly installed. If it is not installed, or if the Eclipse variable ILOG_EXECUTION_SERVER_HOME is not set correctly, an error occurs and you are unable to select a project generator.
- Rulesets can include references to both Java objects and XML objects.