Executing decision services with execution Java API

You can execute decisions in a Java™ application that is running in a Kubernetes container by using the execution Java API for Automation Decision Services.

The execution Java API does not use or depend on any installed services in Automation Decision Services. It does not use the decision runtime REST API or decision service storage. Instead, decision service archives are directly used in the execution API. These decision service archives can be packaged in your Java application or accessed with a URL.

For more information, see the Execution Java API reference in Reference.

Important:

You must enable metering to track usage before you use the execution Java API. For more information, see Tracking usage.

Environment

The execution API can be used in an environment in Java 8 or 11. The Java libraries that are used by the external libraries for your decision services must be compatible with the Java version (Java 8 or 11) for the execution.

Restriction: The execution API is not compatible with decision service archives that are generated in Automation Decision Services V21.0.3 or older.

Samples

Samples that use the execution Java API are available in GitHub. Click Automation Decision Services samples to be redirected to the GitHub repository.
  • Sample: Executing a decision service in Java (available in the ExecutionApiSample subfolder) – You can execute decision services by using the execution Java API, and display execution traces.
  • Sample: Creating a web microservice for executing a decision service (available in the WebMicroServiceSample subfolder) – You can create a web microservice to execute a decision service. You can use a decision service with or without a predictive model.