Configuring an Enterprise Data Grid in a stand-alone environment for dynamic caching

Copy and modify these deployment and objectGrid descriptor files in order to configure an enterprise grid for dynamic caching. These files are used to start an enterprise data grid.

About this task

When WebSphere® eXtreme Scale is specified as the provider for a WebSphere Application Server dynamic cache instance, the WebSphere eXtreme Scale servers are started in either a stand-alone environment or within a WebSphere Application Server environment, see Starting and stopping stand-alone servers for more information. This process requires the use of deployment and objectGrid descriptor files that are used to configure the enterprise data grid. Dynamic caching requires a specific configuration. Therefore, several XML files are delivered with WebSphere eXtreme Scale that are intended to be copied, altered (as needed), and used to start the enterprise data grid. These files can be used as-is, but are subject to change and therefore should be copied to a separate location before they are altered or used.
Note: Depending on how you have installed WebSphere eXtreme Scale, these files are located in either the was_root/optionalLibraries/ObjectGrid/dynacache/etc directory for installations with WebSphere Application Server; or for an installation in a stand-alone environment, these files are located in wxs_install_root/ObjectGrid/dynacache/etc directory.
Important: It is highly recommended that these files be copied to some other location before they are edited or used.
Dynamic cache descriptor file (dynacache-deployment.xml)
This file is the deployment descriptor file for starting a container server for dynamic caching, see Deployment policy descriptor XML file for more information. Although this file can be used as-is, the following following elements or attributes are occasionally changed or have significant importance:
  • mapSet name and map ref

    The name attribute in mapSet, and the defined value for map ref do not directly correspond to the dynamic cache instance name configured for WebSphere Application Server and are typically not changed. If, however, these values are changed, then corresponding custom properties must be added to the configuration of the dynamic cache instance. For more information, see Customizing a dynamic cache instance with custom properties.

  • numberOfPartitions

    This attribute may be changed to represent the appropriate number of partitions for your configuration. For more information, see Planning environment capacity.

  • maxAsyncReplicas

    This attribute may be changed. A dynamic cache typically is used in a side-cache model with a database or some other source as the system of record for the data. As a result, setting this to OPTIMISTIC or NONE will trigger near cache processing, when the eXtreme I/O (XIO) transport type is used, and the space and performance trade-offs required to make the data highly available discourage the use of replication. However, in some cases high availability is important.

  • numInitialContainers

    This attribute should be set to the number of containers that will be included in the initial startup of the enterprise data grid. Having this set correctly will aid in the placement and distribution of partitions throughout the data grid.

Dynamic cache ObjectGrid descriptor XML file (dynacache-objectgrid.xml)
This file is the recommended ObjectGrid descriptor file for starting a container server for dynamic caching, see ObjectGrid descriptor XML file for more information. It is configured to run with the eXtreme I/O transport type (XIO) using eXtreme Data Formatting (XDF). In addition, the Dependency ID and Template ID indexes are configured to use a Global Index, which improves invalidation performance. Although this file can be used as-is, the following following elements or attributes are occasionally changed or have significant importance.
  • objectGrid name and backingMap name

    The name attributes in the objectGrid and backingMap elements do not directly correspond to the dynamic cache instance name configured for WebSphere Application Server cache instance and typically do not need to be changed. If, however, these attributes are changed, then the corresponding custom properties must be added to the configuration of the dynamic cache instance. For more information, see Customizing a dynamic cache instance with custom properties.

  • copyMode

    Set this attribute to COPY_TO_BYTES. This value enables eXtreme Data Format (XDF) when the eXtreme I/O (XIO) transport type is used. Changing to some other copyMode will disable XDF and will require that you uncomment the ObjectTransformer plugin bean.

  • lockStrategy

    Set this attribute to PESSIMISTIC. Setting this to OPTIMISTIC or NONE will trigger near cache processing and must be accompanied with properties from the dynamic-nearcache-objectgrid.xml.

  • backingMapPluginCollections

    This element is required. The child elements Evictor plug-in and MapIndex plug-in are both required for dynamic caching and must not be removed.

  • GlobalIndexEnabled

    Both the DEPENDENCY_ID_INDEX and TEMPLATE_INDEX contain a GlobalIndexEnabled property set to true. Setting this value to false will disable the global index feature for these indexes. It is recommended to leave these global indexes enabled unless you are running with a small number of total partitions, for example, less than 40.

  • objectTransformer

    Since this objectGrid descriptor file is intended to run in eXtreme Data Format (XDF), it has been commented out. If you want to disable XDF (by changing the copyMode value) then you must uncomment this plug-in.

Dynamic near cache ObjectGrid descriptor file (dynacache-nearcache-objectgrid.xml)
This file is the recommended ObjectGrid descriptor file for starting grid container servers for dynamic caching when a near-cache is desired. It is configured to run with the eXtreme I/O transport type (XIO) using eXtreme Data Formatting (XDF). In addition, the Dependency ID and Template indexes are configured to use a Global Index, which improves invalidation performance. The dynamic caching near cache capability requires the use of the eXtreme I/O (XIO) transport type.
Although this file can be used as-is, the following elements or attributes are occasionally changed or have significant importance:
  • objectGrid name and backingMap name

    These values in this file do not directly correspond to the dynamic cache instance name configured for the WebSphere Application Server's cache instance and typically do not need to be changed. If, however, these values are changed, then corresponding custom properties must be added to the configuration of the dynamic cache instance.

  • lockStrategy

    This property must be set to OPTIMISTIC or NONE to enable a near cache. No other lockingStrategy supports a near cache.

  • nearCacheInvalidationEnabled

    This property must be set to true to enable a dynamic caching near cache. This feature uses pub-sub to flow invalidations from the far cache to the near cache instances, keeping them in-sync.

  • nearCacheLastAccessTTLSyncEnabled

    This property must be set to true to enable a dynamic caching near cache. This feature uses pub-sub to flow TTL evictions from the far cache to the near cache instances, keeping them in -sync.

  • copyMode

    This backingMap property is set to COPY_TO_BYTES. This value enables eXtreme Data Format (XDF) when the eXtreme I/O (XIO) transport type is used. Changing to some other copyMode will disable XDF and will require that the ObjectTransformer plugin bean be uncommented.

  • CollisionArbitor

    This public interface decides what value to store when there is a collision on multiple primaries.

  • backingMapPluginCollections

    The MapIndexPlugins and Evictor are mandatory items for dynamic caching and must not be removed.

  • GlobalIndexEnabled

    Both the DEPENDENCY_ID_INDEX and TEMPLATE_INDEX contain a GlobalIndexEnabled property set to true. Setting this value to false will disable the global indexfeature for these indexes. It is recommended to leave these global indexes enabled unless you are running with a small number of total partitions (< 40).

  • ObjectTransformer

    Since this file is intended to run in eXtreme Data Format (XDF) this plugin is commented out. If XDF is to be disabled (via changing the copyMode) then this plugin must be uncommented.

Dynamic legacy ObjectGrid descriptor file (dynacache-legacy85-objectgrid.xml)
This file is the recommended ObjectGrid descriptor file for starting a container server for dynamic caching when you have chosen a near-cache. Although this file can be used as-is, the following elements or attributes are occasionally changed or have significant importance:
  • objectGrid name and backingMap name

    These values in this file do not directly correspond to the dynamic cache instance name configured for the WebSphere Application Server's cache instance and typically do not need to be changed. If, however, these values are changed, then corresponding custom properties must be added to the configuration of the dynamic cache instance.

  • copyMode

    This backingMap property is set to COPY_ON_READ_AND_COMMIT. This value should not be changed.

  • lockStrategy

    This backingMap property is set to PESSIMISTIC. This value should not be changed.

  • backingMapPluginCollections

    The MapIndexPlugins, Evictor, and Object Transformer are mandatory items for dynamic caching and must not be removed.