WebSphere eXtreme Scale Administration Guide > Configure WebSphere eXtreme Scale > Cache integration > WebSphere eXtreme Scale dynamic cache provider



Configure the dynamic cache provider for WebSphere eXtreme Scale


Install and configuring the dynamic cache provider for WebSphere eXtreme Scale depends on what your requirements are and the environment you have set up.


Before you begin

To use the dynamic cache provider, WebSphere eXtreme Scale must be installed on top of the WebSphere Application Server node deployments, including the deployment manager node. See Integrate WebSphere eXtreme Scale with WebSphere Application Server for more information

For information about using the eXtreme Scale dynamic cache provider with IBM WebSphere Commerce, see the following topics in the IBM WebSphere Commerce documentation:

If you are not specifically directing the caching to a defined Object Cache or Servlet Cache instance, then it is likely that the Dynamic Cache API calls are being serviced by the baseCache. To use the eXtreme Scale dynamic cache provider for JSP, Web services or command caching, then you must set the baseCache instance to use the eXtreme Scale dynamic cache provider. The same configuration properties are used to configure the baseCache instance. Remember that these configuration properties need to be set as Java Virtual Machine (JVM) custom properties. This caveat applies to any cache configuration property discussed in this section except for servlet caching.

To use eXtreme Scale with the dynamic cache provider for servlet caching, be sure to configure enablement in system properties rather than custom properties.


Procedure

  1. Enable the eXtreme Scale dynamic cache provider.

    • WebSphere Application Server Version 7.0 and later:

      You can configure the dynamic cache service to use the eXtreme Scale dynamic cache provider with the administrative console. After you install eXtreme Scale, the eXtreme Scale dynamic cache provider is immediately available as a Cache Provider option in the administrative console. For more information, seeWebSphere Application Server Version 7.0 information center: Selecting a cache service provider.

    • WebSphere Application Server Version 6.1:

      Use a custom property to configure the dynamic cache service to use the eXtreme Scale dynamic cache provider. You can also use these custom properties in WebSphere Application Server v7.0 and later.

      To create a custom property on a cache instance, click Resources > Cache instances > cache_instance_type > cache_instance > Custom properties > New. If you are using the base cache instance, create the custom properties on the JVM.

      com.ibm.ws.cache.CacheConfig.cacheProviderName

      To use the eXtreme Scale dynamic cache provider, set the value to com.ibm.ws.objectgrid.dynacache.CacheProviderImpl. You can create this custom property on a dynamic cache instance, or the base cache instance. If you choose to set the custom property on the base cache instance, then all other cache instances on the server use the eXtreme Scale provider by default. Any eXtreme Scale dynamic cache provider configuration properties set for the baseCache are the default configuration properties for all cache instances backed by eXtreme Scale.

      To override the base cache instance and make a particular dynamic cache instance use the default dynamic cache provider, create the com.ibm.ws.cache.CacheConfig.cacheProviderName custom property on the dynamic cache instance and set the value to default.

  2. Optional: If you are using replicated cache instances, configure the replication setting for the cache.

    With the eXtreme Scale dynamic cache provider, you can have local cache instances or replicated cache instances. If you are only using local cache instances, you can skip this step.

    Use one of the following methods to configure the replicated cache:

    • Enable cache replication with the administrative console. You can enable cache replication at any time in WebSphere Application Server v7.0. In WebSphere Application Server v6.1, create a DRS replication domain.

    • Enable cache replication with the com.ibm.ws.cache.CacheConfig.enableCacheReplication custom property to force the cache to report that it is a replicated cache, even though a DRS replication domain has not been assigned to it. Set the value of this custom property to true. Set this custom property on the cache instance if you are using an object cache or servlet cache, or on the JVM if you are using the baseCache instance.

  3. Optional: If you are using eXtreme Scale as a JSP fragment cache, set the com.ibm.ws.cache.CacheConfig.disableTemplateInvalidation custom property to true to disable template-based invalidations during JSP reloads.

  4. Configure the topology for the dynamic cache service.

    The only required configuration parameter for the eXtreme Scale dynamic cache provider is the cache topology. Set the custom property on the dynamic cache service. Enter the name of the custom property as: com.ibm.websphere.xs.dynacache.topology.

    The three possible values for this property follow. You must use one of the allowed values:

    • embedded

    • embedded_partitioned

    • remote

    If you are using embedded or embedded partitioned topologies, consider setting the com.ibm.ws.cache.CacheConfig.ignoreValueInInvalidationEvent custom property to true to save some serialization costs. Set this custom property on the cache instance or the JVM if you are using the baseCache instance.

  5. Optional: If you are using an embedded partitioned topology, configure the number of initial containers for the dynamic cache service.

    You can maximize the performance of caches that are using the embedded partitioned topology by configuring the number of initial containers. Set the variable as a system property on the WebSphere Application Server Java™ virtual machine.

    Enter the name of the property as: com.ibm.websphere.xs.dynacache.num_initial_containers.

    The recommended value of this configuration property is an integer that is equal to or slightly less than the total number of WebSphere Application Server instances that are accessing this distributed cache instance. For example, if a dynamic cache service is shared between data grid members, then the value should be set to the number of data grid members.

  6. Configure the eXtreme Scale catalog service grid.

    When you are using eXtreme Scale as the dynamic cache provider for a distributed cache instance, configure an eXtreme Scale catalog service grid.

    A single catalog service grid can service multiple dynamic cache service providers that are backed by eXtreme Scale. When you run multiple catalog servers, you can connect all the servers together by creating the catalog.services.cluster custom property and setting the value to a list of the catalog server endpoints.

    For more information about creating catalog server endpoints, see Start the catalog service process in a WebSphere Application Server environment.

  7. Configure custom key objects.

    When you are using custom objects as keys the objects must implement the Serializable or Externalizable interface. When you are using the embedded or embedded partitioned topologies, place objects on the WebSphere shared library path, just like if they were being used with the default dynamic cache provider. See Use the DistributedMap and DistributedObjectCache interfaces for the dynamic cache in the WAS ND information center for more details.

    If you are using the remote topology, place the custom key objects on the CLASSPATH for the standalone eXtreme Scale containers. See Start container processes for more information.

  8. Optional: If you are using a remote topology, configure the eXtreme Scale container servers.

    • Embedded or embedded partitioned topology:

      The cached data is stored in WebSphere eXtreme Scale container servers. Container servers can run inside or outside of WebSphere Application Server processes. The eXtreme Scale provider automatically creates containers inside the WebSphere process when you are using embedded or embedded partitioned topologies for a cache instance. No further configuration is needed for these topologies.

    • Remote topology:

      When you are using the remote topology, start up stand-alone eXtreme Scale container servers before the WebSphere Application Server instances that access the cache instance start.

      To start stand-alone containers, see Start container processes. Verify that all the container servers for a specific dynamic cache service point to the same catalog service endpoints.

      The XML configuration files for the stand-alone eXtreme Scale dynamic cache provider containers are in either the <wxs_install_root>/customLibraries/ObjectGrid/dynacache/etc directory for installations on top of WebSphere Application Server, or the <wxs_install_root>/ObjectGrid/dynacache/etc directory for stand-alone installations. The files are named dynacache-remote-objectgrid.xml and dynacache-remote-definition.xml. Make copies of these files to edit and use when you are starting stand-alone containers for the eXtreme Scale dynamic cache provider. The numInitialContainers parameter in the dynacache-remote-deployment.xml file must match the number of container processes that are running.

      The set of container server processes must have enough free memory to service all the dynamic cache instances that are configured to use the remote topology. Any WebSphere Application Server process that shares the same or equivalent values for the catalog.services.cluster custom property must use the same set of stand-alone containers. The number of containers and number of servers on which they reside must be sized appropriately. See Capacity planning and high availability for additional details.

      A command line entry that starts a stand-alone container for the eXtreme Scale dynamic cache provider follows:

      [Unix]

      startOgServer.sh container1 -objectGridFile ../dynacache/etc/dynacache-remote-objectgrid.xml
       -deploymentPolicyFile ../dynacache/etc/dynacache-remote-deployment.xml 
      -catalogServiceEndpoints MyServer1.company.com:2809
      



Parent topic

WebSphere eXtreme Scale dynamic cache provider


+

Search Tips   |   Advanced Search