Customizing the Decision Server Runtime

You can customize the Decision Server Runtime behavior through a configmap that references a properties file with context parameters.

About this task

You can customize the Decision Server Runtime behavior through the context-param properties of the web.xml file. You can do so when you install a new instance of Operational Decision Manager, or when you update an existing instance.

The customization can be applied, for example, to enable asynchronous ruleset parsing in the runtime. For more information, see Ruleset parsing and the ruleset cache.

The following table shows the properties that you can set.

Table 1. Context parameters
Property name Default value Description
AsynchronousRulesetParsing false Specify whether the parsing of the ruleset is asynchronous or not for all HTDS executions.
DefaultTimeZoneForJsonDeserialization default Specify the timezone in which dates are expressed in case they do not contain timezone information, for the REST JSON execution endpoint.

Possible values are: default, server, or a timezone identifier.

  • default: No override of the timezone used by the JSON parser (GMT).
  • server: Override of the timezone used by the JSON parser to use the JVM default timezone.
  • A timezone identifier: Override of the timezone used by the JSON parser to use the specified timezone, if it is a valid timezone.
CheckEmptyJsonRequests true Specify whether to check for empty JSON requests and reject them or not.

Default is true but it might impact performance in case the requested documents are large.

forceSerializationOfNullFieldsDecoratedWithJAXBAnnotations false

Specify whether to force inclusion of null values in JSON responses ({ "fieldName": null}) when corresponding fields are decorated with JAXB annotations like @XmlElement.

Procedure

To customize the context-param properties before the installation of an Operational Decision Manager instance, proceed as follows:

  1. Create a web-configuration.properties file.
    1. Be sure to name the file web-configuration.properties.
    2. Set the context parameters in this file. For example,
      CheckEmptyJsonRequests=false
  2. Create a configmap that references this properties file.
    kubectl create configmap my-odm-web-configmap --from-file web-configuration.properties
  3. Specify this configmap in the Operational Decision Manager helm chart.

    Include the parameter webConfigRef in the helm install command.

    helm install release_name --set license=true --set decisionServerRuntime.webConfigRef=my-odm-web-configmap /path/to/ibm-odm-prod-version.tgz

To update the web.xml configuration in an existing installation of Operational Decision Manager, proceed as follows:

  1. Edit the configmap by running the following command:
     kubectl edit configmap my-odm-ds-runtime-web-configmap

    If you did not set the decisionServerRuntime.webConfigRef parameter when you ran the helm install command, a default configmap is generated with the name release_name-odm-ds-runtime-web-configmap. Edit the generated configmap to customize the web.xml runtime configuration.

    Note: You can also update the web-configuration.properties file and replace it in the configmap by running the following command:
    kubectl create configmap release_name-odm-ds-runtime-web-configmap --from-file web-configuration.properties -o yaml --dry-run | kubectl replace -f -
  2. Delete the decisionserverruntime pod by running the following command:
     kubectl delete pod release_name-odm-decisionserverruntime-XXXX

    A new pod is automatically recreated with the new web.xml configuration properties of the Decision Server Runtime.