Red Hat Training
A Red Hat training course is available for Red Hat Decision Manager
Chapter 5. Running the Business Optimizer examples
Red Hat Business Optimizer includes a number of examples to demonstrate a variety of use cases.
Prerequisite
Download and install Red Hat Decision Manager from the Red Hat Customer Portal.
Procedure
-
Download the
rhdm-7.0.0.GA-add-ons.zip
file from the Red Hat Decision Manager section of the Red Hat Customer Portal. -
Extract the Red Hat Business Optimizer engine from the
rhdm-7.0.0.GA-planner-engine.zip
file. In the
rhdm-7.0.0.GA-planner-engine
folder, open theexamples
directory and use the appropriate script to run the examples:Linux or Mac:
$ cd examples $ ./runExamples.sh
Windows:
$ cd examples $ runExamples.bat
Select and run an example from the GUI application window:
Red Hat Business Optimizer itself has no GUI dependencies. It runs just as well on a server or a mobile JVM as it does on the desktop.
5.1. Running the Red Hat Business Optimizer examples in an IDE (IntelliJ, Eclipse, or Netbeans)
Use the following procedure to run the Red Hat Business Optimizer examples in IntelliJ or Netbeans:
Procedure
Open the file
examples/sources/pom.xml
as a new project.The Maven integration will take care of the rest of the installation.
Use the following procedure to run the Red Hat Business Optimizer examples in Eclipse:
Procedure
-
Open a new project for the directory
examples/sources
. -
Add all the JARs to the classpath from the directory
binaries
and the directoryexamples/binaries
, except for the fileexamples/binaries/optaplanner-examples-*.jar
. -
Add the Java source directory
src/main/java
and the Java resources directorysrc/main/resources
. Create a run configuration:
-
Main class:
org.optaplanner.examples.app.OptaPlannerExamplesApp
-
VM parameters (optional):
-Xmx512M -server
-
Working directory:
examples/sources
-
Main class:
- Run the run configuration.