This topic explains how to check redundancy in VMware Tanzu GemFire partitioned regions.
Under some circumstances, it can be important to verify that your partitioned region data is redundant and that upon member restart, redundancy has been recovered properly across partitioned region members.
Initiate an operation to report the current redundancy status of regions using one of the following:
gfsh
command. Start gfsh
and connect to the cluster. Then type the following command:
gfsh>status redundancy
Optionally, you can specify regions to include or exclude from restoring redundancy. Type help restore redundancy
or see status redundancy for more information.
API call:
ResourceManager manager = cache.getResourceManager();
RestoreRedundancyResults currentStatus = manager.createRestoreRedundancyOperation().redundancyStatus();
//These are some of the details we can get about the run from the API
System.out.println("Status for all regions: " + currentStatus.getMessage());
System.out.println("Number of regions with no redundant copies: " + currentStatus.getZeroRedundancyRegionResults().size();
System.out.println("Status for region " + regionName + ": " + currentStatus.getRegionResult(regionName).getMessage();
If you have startup-recovery-delay=-1
configured for your partitioned region, you will need to trigger a restore redundancy operation on your region after you restart any members in your cluster in order to recover redundancy. See Restoring Redundancy in Partitioned Regions.
If you have startup-recovery-delay
set to a low number, you may need to wait extra time until the region has recovered redundancy.