Configuring Java shared classes

CICS® Transaction Gateway uses the Java™ shared classes feature to improve performance.

Java shared classes provides a transparent and dynamic way of sharing loaded classes that places no restrictions on Java Virtual Machines (JVMs) that are sharing class data. Java shared classes helps reduce virtual memory usage and can improve startup time. CICS Transaction Gateway creates a class cache called cicstgvrm%g, where vrm is the version, release and modification level of CICS Transaction Gateway, and %g is the group name of the user that is running the Gateway daemon job. The cache is created in the /tmp/javasharedresources directory unless the location is overridden with the cachedir sub-option. The class cache options used by the Gateway daemon are output in message CTG6134I during initialization.

The available sub-options are:

Sets the operating system permissions on a new cache to allow group access to the cache. The default is user access only.
Creates a nonpersistent cache in shared memory. The shared memory (and the cache) are lost when the operating system shuts down. Nonpersistent and persistent caches can have the same name. You must always use the nonpersistent suboption when running utilities such as destroy on a nonpersistent cache. The default is persistent.
Ensures that the JVM ignores any potentially fatal permission problems or disk space problems, and attempts to start normally and to operate normally. For example a JVM does not attempt to open a readonly cache unless a JVM read/write operation on that cache previously failed.
By default, the following class cache options are specified when the Gateway daemon starts:

For more information on the Java shared class cache options see your Java documentation.

To override the options used by CICS Transaction Gateway for the -Xshareclasses, set the CTGSTART_OPTS CICS TG environment variable, for example:


To disable class caching for the Gateway daemon, specify the following option:


To list all the valid sub-options to -Xshareclasses, type the following in the bin directory of your Java installation:

java -Xshareclasses:help

If Gateway daemons using the same Java major version are started on the same LPAR by different user IDs, you must ensure that all user IDs have access to the relevant class cache entities. For more information see your Java documentation.