此内容没有您所选择的语言版本。

Chapter 38. Rolling Upgrades


38.1. Performing Rolling Upgrades

Upgrade Red Hat JBoss Data Grid clusters without downtime or data loss.

You can perform rolling upgrades only:

  • in Remote Client-Server mode.
  • using the Hot Rod protocol.
Tip

38.1.1. Setting Up the Target Cluster

The target cluster is the desired version of JBoss Data Grid to which you migrate data.

Note

Rolling upgrades are supported from JBoss Data Grid version 6.6.2.

  1. Start the target cluster with unique network properties or a different JGroups cluster name to keep it separate from the source cluster.
  2. Configure a RemoteCacheStore on each node in the target cluster for each cache you want to migrate from the source cluster.

    Note

    The RemoteCacheStore on the target cluster is in addition to any other persistent store.

    RemoteCacheStore settings
    • remote-server must point to the source cluster via the outbound-socket-binding property.
    • remoteCacheName must match the cache name on the source cluster.
    • hotrod-wrapping must be true (enabled).
    • shared must be true (enabled).
    • purge must be false (disabled).
    • passivation must be false (disabled).
    • protocol-version matches the Hot Rod protocol version of the source cluster.

      Expand

      JBoss Data Grid Version

      Hot Rod Protocol Version

      7.2

      2.6

      7.1

      2.6

      7.0

      2.5

      6.6.2

      2.4 (Requires 2.5.)
      If you plan to perform a rolling upgrade from JBoss Data Grid version 6.6.2, contact your Red Hat support team to upgrade to Hot Rod version 2.5.

Example RemoteCacheStore Configuration

<distributed-cache>
   <remote-store cache="MyCache" socket-timeout="60000" tcp-no-delay="true" protocol-version="2.5" shared="true" hotrod-wrapping="true" purge="false" passivation="false">
      <remote-server outbound-socket-binding="remote-store-hotrod-server"/>
   </remote-store>
</distributed-cache>
...
<socket-binding-group name="standard-sockets" default-interface="public" port-offset="${jboss.socket.binding.port-offset:0}">
  ...
  <outbound-socket-binding name="remote-store-hotrod-server">
     <remote-destination host="198.51.100.0" port="11222"/>
  </outbound-socket-binding>
  ...
</socket-binding-group>
Copy to Clipboard Toggle word wrap

38.1.2. Migrating Data to the Target Cluster

  1. Configure the target cluster to handle all client requests instead of the source cluster:

    1. Configure all clients to point to the target cluster instead of the source cluster.
    2. Restart each client node.

      The target cluster lazily loads data from the source cluster on demand via RemoteCacheStore.

  2. Fetch data from the source cluster.

    Note

    You synchronize data on the target cluster to fetch data from the source cluster. If you are migrating from JBoss Data Grid 6.6.2, you must synchronize data on each node in the target cluster.

    Do one of the following on the target cluster for each cache that you want to migrate:

    JMX
    Invoke the synchronizeData operation and specify the hotrod parameter on the RollingUpgradeManager MBean. See RollingUpgradeManager.
    CLI
    $ JDG_HOME/bin/cli.sh --connect controller=127.0.0.1:9990 -c "/subsystem=datagrid-infinispan/cache-container=clustered/distributed-cache=MyCache:synchronize-data(migrator-name=hotrod)"
    Copy to Clipboard Toggle word wrap

    Data migrates to all nodes in the target cluster in parallel, with each node receiving a subset of the data.

    Use the following parameters to tune the operation:

    • read-batch configures the number of entries to read from the source cluster at a time. The default value is 10000.
    • write-threads configures the number of threads used to write data. The default value is the number of processors available.

      For example:

      synchronize-data(migrator-name=hotrod, read-batch=100000, write-threads=3)

The synchronizeData method call is blocking so no other operations are performed until the data migration is complete.

38.1.3. Finalizing Rolling Upgrades

After the target cluster fetches all data from the source cluster, do the following:

  1. Disable the RemoteCacheStore on the target cluster.

    Note

    You must complete this step on each node in the target cluster.

    Do one of the following:

    JMX
    Invoke the disconnectSource operation and specify the hotrod parameter on the RollingUpgradeManager MBean. See RollingUpgradeManager.
    CLI
    $ JDG_HOME/bin/cli.sh --connect controller=127.0.0.1:9990 -c "/subsystem=datagrid-infinispan/cache-container=clustered/distributed-cache=MyCache:disconnect-source(migrator-name=hotrod)"
    Copy to Clipboard Toggle word wrap
  2. Decommission the source cluster.
返回顶部
Red Hat logoGithubredditYoutubeTwitter

学习

尝试、购买和销售

社区

关于红帽文档

通过我们的产品和服务,以及可以信赖的内容,帮助红帽用户创新并实现他们的目标。 了解我们当前的更新.

让开源更具包容性

红帽致力于替换我们的代码、文档和 Web 属性中存在问题的语言。欲了解更多详情,请参阅红帽博客.

關於紅帽

我们提供强化的解决方案,使企业能够更轻松地跨平台和环境(从核心数据中心到网络边缘)工作。

Theme

© 2025 Red Hat