gedi-geode-extensions-core/src/main/java/gedi/solutions/geode/util/GemFireMgmt.java
public static void shutDownRedundancyZone(String redundancyZone)
   {
	   if (redundancyZone == null || redundancyZone.length() == 0)
		   throw new IllegalArgumentException("redundancyZone required");
	   
	   String objectNamePattern = "GemFire:type=Member,member=*";
	   QueryExp exp = Query.eq(Query.attr("RedundancyZone"),Query.value(redundancyZone));
	   
	   Collection<ObjectName> memberObjectNames = SingletonGemFireJmx.getJmx().searchObjectNames(objectNamePattern, exp);
	   for (ObjectName objectName : memberObjectNames)
	   {
		   GemFireMgmt.shutDownMember(objectName.getKeyProperty("member"));
	   }
   }
public static void shutDownRedundancyZone(String redundancyZone)
   {
	   if (redundancyZone == null || redundancyZone.length() == 0)
		   throw new IllegalArgumentException("redundancyZone required");
	   
	   String objectNamePattern = "GemFire:type=Member,member=*";
	   QueryExp exp = Query.eq(Query.attr("RedundancyZone"),Query.value(redundancyZone));
	   
	   Collection<ObjectName> memberObjectNames = SingletonGemFireJmx.getJmx().searchObjectNames(objectNamePattern, exp);
	   for (ObjectName objectName : memberObjectNames)
	   {
		   GemFireMgmt.shutDownMember(objectName.getKeyProperty("member"));
	   }
   }
public static void shutDownRedundancyZone ( String redundancyZone ) { if ( redundancyZone == null || redundancyZone . length ( ) == 0 ) throw new IllegalArgumentException ( "redundancyZone required" ) ; String objectNamePattern = "GemFire:type=Member,member=*" ; QueryExp exp = Query . eq ( Query . attr ( "RedundancyZone" ) , Query . value ( redundancyZone ) ) ; Collection < ObjectName > memberObjectNames = SingletonGemFireJmx . getJmx ( ) . searchObjectNames ( objectNamePattern , exp ) ; for ( ObjectName objectName : memberObjectNames ) { GemFireMgmt . shutDownMember ( objectName . getKeyProperty ( "member" ) ) ; } }
Shut down each member in a given RedundancyZone
@param redundancyZone the Redundancy Zone to shutdown
Shut down each member in a given RedundancyZone