Tutorials > Dynamic caching > Operate dynacache in a production environment

< Previous | Next >

Set up cache replication in a clustered environment

In a clustered environment, set up cache replication for dynamic cache services to work properly.

When setting up cache replication, it is not necessary to replicate all cache entries. You can control the cache replication policy on a cluster member level or on an individual cache entry level.


  1. Start the WebSphere Application Server administration server.

  2. Launch the WebSphere administrative console.

  3. Create an Internal Replication Domain for the application.

    It is possible to create this as part of the initial cluster setup. If you have already created a Replication Domain for the application, you can use the existing one.

    1. Click...

      Environment | Replication domains | New

    2. Fill in the required fields. For Number of replicas, select Entire Domain. Save the changes.

  4. Enable cache replication in each clone.

    1. Click...

      Servers | Application servers | server_name | Container Services | Dynamic Cache Service | Enable Cache Replication

    2. Choose a replication domain.

    3. Choose a replication type. For WebSphere Commerce, the recommendation is to use Not shared.

    4. Repeat steps a-d for each clone.

    5. Save the changes.

  5. Instead of using a default setting, always explicitly specify the replication mode for each entry in cachespec.xml. For example:

    • Add <sharing-policy>shared-push</sharing-policy> to each cache-entry in cachespec.xml.

    • Note: You can choose not to replicate certain cache entries.

      To configure a cache entry to not replicate, set < sharing-policy>not-shared</sharing-policy>. See the cachespec.xml.

      For more information, see Configuring cache replicationin the WebSphere Application Server documentation.

  6. Restart all the servers.

  7. Use the Cache Monitor to verify that replication is working.

< Previous | Next >


Search Tips   |   Advanced Search