You can customize the JVM options in an Operational Decision Manager production deployment at
installation time, or use the default settings. You use the jvmOptionsRef
parameters in the custom resources .yaml file.
About this task
When you install Operational Decision Manager,
the following configmap files are generated. They define the default Liberty
server JVM options for each Operational Decision Manager component.
Table 1. Naming convention for configmap files
| Component |
Name of configmap |
| Decision Center |
<instance_name>-odm-dc-jvm-options-configmap |
| Decision Runner |
<instance_name>-odm-dr-jvm-options-configmap |
| Decision Server
console |
<instance_name>-odm-ds-console-jvm-options-configmap |
| Decision Server
runtime |
<instance_name>-odm-ds-runtime-jvm-options-configmap |
Where <instance_name> is the name of the custom resource file.
By default, the only JVM option in the Decision Center
configmap file is the time zone.
-Duser.timezone=Europe/Paris
Note: You perform the following steps when you configure the custom resource (CR).
Procedure
-
Create a jvm.options file with the new settings for the Liberty JVM.
The name must be
jvm.options as it replaces the default file in the
container.
Tip: If you need to add multiple options in
Decision Center or in the other components,
separate the options by using the
\n separator.
-Dprop1=val1\n-Dprop2=val2
-
Create a configmap with a key that corresponds to the component that you
want to modify.
The following keys must be used:
- Decision Center:
dc-jvm-options
- Decision Runner: dr-jvm-options
- Decision Server console:
dsc-jvm-options
- Decision Server runtime:
dsr-jvm-options
For example, to create a JVM options configmap for Decision Center, enter the following
command:
kubectl create configmap my-odm-dc-jvm-options-configmap --from-file=dc-jvm-options=jvm.options
-
Associate the new configmap to the application definition by using the
appropriate jvmOptionsRef parameter in the custom resource
.yaml file that the operator used to deploy Operational Decision Manager.
For example, to change the logging in Decision Center, specify the following in
the .yaml file:
decisionCenter:
jvmOptionsRef: my-odm-dc-jvm-options-configmap
-
To update the existing containers, run the
kubectl apply command on the custom
resource .yaml file.
kubectl apply -f custom_resources.yaml
Results
The operator modifies the application to use the new configmap and updates
the /config/configDropins/overrides/jvm.options file.