Configuring the Java Service Wrapper

About this task

The Java Service Wrapper is a utility program developed by Tanuki Software, Ltd that is used to launch the JVM in which Optimize runs. You can control various aspects of Optimize components using settings that control how the Java Service Wrapper runs. This section describes how to customize some of the settings used by the Java Service Wrapper.

In addition to launching the JVM, the Java Service Wrapper offers features for monitoring the JVM, logging console output, and generating thread dumps. The following sections describe how Optimize uses the features of the Java Service Wrapper. For an overview of the Java Service Wrapper, see the IBM webMethods Infrastructure Administrator's Guide cross-product document.

There are three Optimize components for which Java Service Wrapper configuration settings can be adjusted. These components are Analytic Engine, Web Service Data Collector, and Infrastructure Data Collector. There are numerous Java Service Wrapper settings that can be modified for these components, but IBM only recommends modifications to only two parameters: log level and memory allocation. Other settings should not be customized unless you are directed to do so by IBM support.

For applicable Optimize components, the configuration files for the Java Service Wrapper reside in the following folders.
  • The Analytic Engine Java Service Wrapper configuration files reside in the following folder:

    Software AG_directory/optimize/analysis/conf/wrapper.conf

  • The Web Service Data Collector Java Service Wrapper configuration file resides in the following folder:

    Software AG_directory/optimize/dataCollector/conf/wrapper.conf

  • The Infrastructure Data Collector Java Service Wrapper configuration file resides in the following folder:

    Software AG_directory/profiles/InfraDC/configuration/custom_wrapper.conf

When you start Optimize, property settings in the wrapper.conf and the custom_wrapper.conf files determine the configuration of the JVM and the behavior of the logging and monitoring features of the Java Service Wrapper.

The following table provides more information about the wrapper.conf and the custom_wrapper.conf files.
File name Description
wrapper.conf Contains property settings that are installed by Optimize. You must edit this file directly to change Java Service wrapper settings for Analytic Engine and Web service Data Collector.
custom_wrapper.conf For Infrastructure Data Collector, this file contains properties that modify the installed settings in wrapper.conf.

If you need to modify the property settings for the Java Service Wrapper for Infrastructure Data Collector, make your changes in this file.

The following sections describe configuration changes that Optimize supports for Java Service Wrapper. For Optimize, do not make any configuration changes to the Java Service Wrapper other than the ones described in the following sections unless directed to do so by IBM support.

When the Java Service Wrapper launches the JVM, it provides configuration settings that, among other things, specify the size of the Java heap, the size of the PermGen area, and the directories in the classpath.

The wrapper.java properties in the Java Service Wrapper configuration files determine the configuration of the JVM in which Optimize runs.

The JVM property settings that Optimize installs are suitable for most environments. However, you can modify the following properties if the installed settings do not suit your needs. For procedures and additional information, see the webMethods cross-product document, IBM webMethods Infrastructure Administrator's Guide.

Specifying the JDK or JRE for Analytic Engine, Infrastructure Data Collector and Web Service Data Collector

About this task

Optimize Analytic Engine, Optimize Infrastructure Data Collector and Web Service Data Collector must point to a JDK or JRE. By default, they point to the location of the JDK installed at the same time you installed Optimize. If necessary, you can specify a different location.

Before you specify the location of Java for Analytic Engine, Infrastructure Data Collector and Web Service Data Collector determine whether you need to specify the location of the JDK or the JRE.

Important: If you specify a different JDK or JRE, do not remove the JDK or JRE that IBM webMethods Installer installed with Optimize. The JDK and JRE installed with Optimize are required to run the IBM webMethods Uninstaller.

To specify the Java location for Analytic Engine, Infrastructure Data Collector and Web Service Data Collector

Procedure

  1. Open the wrapper.conf file in a text editor. You can find the respective wrapper.conf file in the following locations:
    • The Analytic Engine Java Service Wrapper configuration file resides in the following folder: Software AG_directory/optimize/analysis/conf/wrapper.conf
    • The Infrastructure Data Collector Java Service Wrapper configuration file resides in the following folder: Software AG_directory/profiles/InfraDC/configuration/wrapper.conf
    • The Web Service Data Collector Java Service Wrapper configuration file resides in the following folder: Software AG_directory/optimize/dataCollector/conf/wrapper.conf
  2. Set the wrapper.java.command property so that it specifies the location of the JDK or JRE installation directory. For example:

    wrapper.java.command=C:\SoftwareAG\jvm\jvm\bin\java

  3. Save and close the file.
  4. Restart Analytic Engine, Infrastructure Data Collector and Web Services Data Collector.

Configuring JVM Memory Allocation

The following table provides information about setting the initial and maximum memory allocation for the JVM at startup.

Property Value
wrapper.java.initmemory Initial size (in MB) of the Java heap. For the Analytic Engine, the recommended value is 100
Note: If you specify a value for the wrapper.java.initmemory memory property, make sure that it is smaller than the value of the wrapper.java.maxmemory property.
wrapper.java.maxmemory Maximum size (in MB) to which the Java heap can grow.

For Analytic Engine, the recommended value is 900.

To use the default values that are configured in the JVM itself, specify zero (0) in the properties of the wrapper.conf file. If you configure the memory amount in the Java wrapper (a non-zero value), the wrapper adds an appropriate -Xms parameter. However, if you configure the default JVM memory amount (a zero value), you can set the -Xms parameter manually as an additional property in the configuration file.

The Wrapper Log

The Java Service Wrapper records console output in a log file. The log contains the output sent to the console by the wrapper itself and by the JVM in which Optimize is running. The wrapper log is especially useful when you run Optimize as a Windows service, because console output is normally not available to you in this mode.

The Java Service Wrapper log files for Optimize components are located in the following locations:

  • Analytic Engine: Software AG_directory\Optimize\analysis\bin\wrapper.log
  • Web Service Data Collector: Software AG_directory\Optimize\dataCollector\bin\wrapper.log
  • Infrastructure Data Collector: Software AG_directory\profiles\InfraDC\logs

To view a log file, open the log file in a text editor.

Logging Properties

The wrapper.console and wrapper.log properties in the wrapper configuration files determine the content, format, and behavior of the wrapper log.

The logging settings that Optimize installs are suitable for most environments. However, you can modify the following properties if the installed settings do not suit your needs. For procedures and additional information, see IBM webMethods Infrastructure Administrator's Guide.

The following table describes the wrapper.console and wrapper.log properties.
Property Value
wrapper.console.loglevel Level of messages to display in the console.
wrapper.console.format Format of messages in the console.
wrapper.logfile File in which to log messages.
wrapper.logfile.loglevel Level of messages to write in the log file.
wrapper.logfile.format Format of messages in the log file.
wrapper.logfile.maxsize Maximum size to which the log can grow.
wrapper.logfile.maxfiles Number of old logs to maintain.
wrapper.syslog.loglevel Level of messages to write to the Event Log on Windows systems or the syslog on UNIX.
Important: Configure the wrapper.logfile.maxsize and wrapper.logfile.maxfiles properties in the wrapper configuration files to ensure that the processing of personal data is according to GDPR.

Configuring Additional JVM Parameters

About this task

You can define and configure some additional Java parameters that are passed to the JVM when it is started. You define the additional parameters in the wrapper.conf file in the same way you configure memory allocation, as described in Configuring the Java Service Wrapper. Each additional parameter is defined in the form:

wrapper.java.additional.<n>=<parameter>
where:
  • <n> is a numeric value, starting with 1 for the first additional parameter, and then incrementing by one for each consecutive parameter.
  • <parameter> is the parameter name and value.

To configure additional JVM parameters

Procedure

  1. Browse to Software AG_directory/optimize/analysis/conf/ and open the wrapper.conf file for editing.
  2. Define the most frequently used additional parameters.
    The following table describes the additional JVM parameters.
    Parameter Value
    wrapper.java.additional.<n>= -Xsssize 256k
    Note: Set this value to 512k for HP-UX 64-bit.
    wrapper.java.additional.<n>= -XX:PermSize=value The default value for PermSize is set by the JVM. In the event of Perm out of memory errors, use this parameter to increase the PermSize value.
    wrapper.java.additional.<n>= -XX:MaxPermSize=value The default value for MaxPermSize is set by the JVM. In the event of Perm out of memory errors, use this parameter to increase the MaxPermSize value.
  3. Save the wrapper.conf file.
  4. If the Analytic Engine is running, restart it to apply the modifications.