geode-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jensde...@apache.org
Subject [02/24] geode git commit: GEODE-2818: add alias to any command's options that involves "group", "member", "jar" and replace CliString variables with GROUP, MEMBER, JAR, etc.
Date Mon, 19 Jun 2017 15:23:35 GMT
http://git-wip-us.apache.org/repos/asf/geode/blob/db8e1df3/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandCreateGatewayReceiverDUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandCreateGatewayReceiverDUnitTest.java b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandCreateGatewayReceiverDUnitTest.java
index 63cf594..bdccabe 100644
--- a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandCreateGatewayReceiverDUnitTest.java
+++ b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandCreateGatewayReceiverDUnitTest.java
@@ -51,14 +51,14 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
   public void testCreateGatewayReceiverWithDefault() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm4.invoke(() -> createCache(punePort));
@@ -104,14 +104,14 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
   public void testCreateGatewayReceiver() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm4.invoke(() -> createCache(punePort));
@@ -157,14 +157,14 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
   public void testCreateGatewayReceiverWithGatewayTransportFilter() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm4.invoke(() -> createCache(punePort));
@@ -215,14 +215,14 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
   public void testCreateGatewayReceiverWithMultipleGatewayTransportFilters() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm4.invoke(() -> createCache(punePort));
@@ -273,14 +273,14 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
   public void testCreateGatewayReceiver_Error() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm4.invoke(() -> createCache(punePort));
@@ -319,20 +319,20 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
   public void testCreateGatewayReceiver_onMember() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm4.invoke(() -> createCache(punePort));
     vm5.invoke(() -> createCache(punePort));
 
-    final DistributedMember vm3Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm3Member = vm3.invoke(() -> getMember());
 
     String command =
         CliStrings.CREATE_GATEWAYRECEIVER + " --" + CliStrings.CREATE_GATEWAYRECEIVER__MANUALSTART
@@ -341,7 +341,7 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
             + CliStrings.CREATE_GATEWAYRECEIVER__ENDPORT + "=11000" + " --"
             + CliStrings.CREATE_GATEWAYRECEIVER__MAXTIMEBETWEENPINGS + "=100000" + " --"
             + CliStrings.CREATE_GATEWAYRECEIVER__SOCKETBUFFERSIZE + "=512000" + " --"
-            + CliStrings.CREATE_GATEWAYRECEIVER__MEMBER + "=" + vm3Member.getId();
+            + CliStrings.MEMBER + "=" + vm3Member.getId();
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -372,21 +372,21 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
   public void testCreateGatewayReceiver_onMultipleMembers() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm4.invoke(() -> createCache(punePort));
     vm5.invoke(() -> createCache(punePort));
 
-    final DistributedMember vm3Member = (DistributedMember) vm3.invoke(() -> getMember());
-    final DistributedMember vm4Member = (DistributedMember) vm4.invoke(() -> getMember());
+    final DistributedMember vm3Member = vm3.invoke(() -> getMember());
+    final DistributedMember vm4Member = vm4.invoke(() -> getMember());
 
     String command =
         CliStrings.CREATE_GATEWAYRECEIVER + " --" + CliStrings.CREATE_GATEWAYRECEIVER__MANUALSTART
@@ -395,8 +395,7 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
             + CliStrings.CREATE_GATEWAYRECEIVER__ENDPORT + "=11000" + " --"
             + CliStrings.CREATE_GATEWAYRECEIVER__MAXTIMEBETWEENPINGS + "=100000" + " --"
             + CliStrings.CREATE_GATEWAYRECEIVER__SOCKETBUFFERSIZE + "=512000" + " --"
-            + CliStrings.CREATE_GATEWAYRECEIVER__MEMBER + "=" + vm3Member.getId() + ","
-            + vm4Member.getId();
+            + CliStrings.MEMBER + "=" + vm3Member.getId() + "," + vm4Member.getId();
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -428,14 +427,14 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
   public void testCreateGatewayReceiver_onGroup() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCacheWithGroups(punePort, "receiverGroup1"));
     vm4.invoke(() -> createCacheWithGroups(punePort, "receiverGroup1"));
@@ -448,7 +447,7 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
             + CliStrings.CREATE_GATEWAYRECEIVER__ENDPORT + "=11000" + " --"
             + CliStrings.CREATE_GATEWAYRECEIVER__MAXTIMEBETWEENPINGS + "=100000" + " --"
             + CliStrings.CREATE_GATEWAYRECEIVER__SOCKETBUFFERSIZE + "=512000" + " --"
-            + CliStrings.CREATE_GATEWAYRECEIVER__GROUP + "=receiverGroup1";
+            + CliStrings.GROUP + "=receiverGroup1";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -483,14 +482,14 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
   public void testCreateGatewayReceiver_onGroup_Scenario2() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCacheWithGroups(punePort, "receiverGroup1"));
     vm4.invoke(() -> createCacheWithGroups(punePort, "receiverGroup1"));
@@ -503,7 +502,7 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
             + CliStrings.CREATE_GATEWAYRECEIVER__ENDPORT + "=11000" + " --"
             + CliStrings.CREATE_GATEWAYRECEIVER__MAXTIMEBETWEENPINGS + "=100000" + " --"
             + CliStrings.CREATE_GATEWAYRECEIVER__SOCKETBUFFERSIZE + "=512000" + " --"
-            + CliStrings.CREATE_GATEWAYRECEIVER__GROUP + "=receiverGroup1";
+            + CliStrings.GROUP + "=receiverGroup1";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -535,14 +534,14 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
   public void testCreateGatewayReceiver_onMultipleGroups() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCacheWithGroups(punePort, "receiverGroup1"));
     vm4.invoke(() -> createCacheWithGroups(punePort, "receiverGroup1"));
@@ -555,7 +554,7 @@ public class WanCommandCreateGatewayReceiverDUnitTest extends WANCommandTestBase
             + CliStrings.CREATE_GATEWAYRECEIVER__ENDPORT + "=11000" + " --"
             + CliStrings.CREATE_GATEWAYRECEIVER__MAXTIMEBETWEENPINGS + "=100000" + " --"
             + CliStrings.CREATE_GATEWAYRECEIVER__SOCKETBUFFERSIZE + "=512000" + " --"
-            + CliStrings.CREATE_GATEWAYRECEIVER__GROUP + "=receiverGroup1,receiverGroup2";
+            + CliStrings.GROUP + "=receiverGroup1,receiverGroup2";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);

http://git-wip-us.apache.org/repos/asf/geode/blob/db8e1df3/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewayReceiverStartDUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewayReceiverStartDUnitTest.java b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewayReceiverStartDUnitTest.java
index 40c0f1b..9f97dd7 100644
--- a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewayReceiverStartDUnitTest.java
+++ b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewayReceiverStartDUnitTest.java
@@ -48,22 +48,21 @@ public class WanCommandGatewayReceiverStartDUnitTest extends WANCommandTestBase
   public void testStartGatewayReceiver_ErrorConditions() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createReceiver(punePort));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
 
-    String command =
-        CliStrings.START_GATEWAYRECEIVER + " --" + CliStrings.START_GATEWAYRECEIVER__MEMBER + "="
-            + vm1Member.getId() + " --" + CliStrings.START_GATEWAYRECEIVER__GROUP + "=RG1";
+    String command = CliStrings.START_GATEWAYRECEIVER + " --" + CliStrings.MEMBER + "="
+        + vm1Member.getId() + " --" + CliStrings.GROUP + "=RG1";
 
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
@@ -82,14 +81,14 @@ public class WanCommandGatewayReceiverStartDUnitTest extends WANCommandTestBase
   public void testStartGatewayReceiver() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createReceiver(punePort));
     vm4.invoke(() -> createReceiver(punePort));
@@ -126,14 +125,14 @@ public class WanCommandGatewayReceiverStartDUnitTest extends WANCommandTestBase
   public void testStartGatewayReceiver_onMember() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createReceiver(punePort));
     vm4.invoke(() -> createReceiver(punePort));
@@ -143,10 +142,10 @@ public class WanCommandGatewayReceiverStartDUnitTest extends WANCommandTestBase
     vm4.invoke(() -> verifyReceiverState(false));
     vm5.invoke(() -> verifyReceiverState(false));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
     pause(10000);
-    String command = CliStrings.START_GATEWAYRECEIVER + " --"
-        + CliStrings.START_GATEWAYRECEIVER__MEMBER + "=" + vm1Member.getId();
+    String command =
+        CliStrings.START_GATEWAYRECEIVER + " --" + CliStrings.MEMBER + "=" + vm1Member.getId();
 
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
@@ -171,14 +170,14 @@ public class WanCommandGatewayReceiverStartDUnitTest extends WANCommandTestBase
   public void testStartGatewayReceiver_Group() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createReceiverWithGroup(punePort, "RG1"));
     vm4.invoke(() -> createReceiverWithGroup(punePort, "RG1"));
@@ -189,8 +188,7 @@ public class WanCommandGatewayReceiverStartDUnitTest extends WANCommandTestBase
     vm5.invoke(() -> verifyReceiverState(false));
 
     pause(10000);
-    String command =
-        CliStrings.START_GATEWAYRECEIVER + " --" + CliStrings.START_GATEWAYRECEIVER__GROUP + "=RG1";
+    String command = CliStrings.START_GATEWAYRECEIVER + " --" + CliStrings.GROUP + "=RG1";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -220,14 +218,14 @@ public class WanCommandGatewayReceiverStartDUnitTest extends WANCommandTestBase
   public void testStartGatewayReceiver_MultipleGroup() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createReceiverWithGroup(punePort, "RG1"));
     vm4.invoke(() -> createReceiverWithGroup(punePort, "RG1"));
@@ -242,8 +240,7 @@ public class WanCommandGatewayReceiverStartDUnitTest extends WANCommandTestBase
     vm7.invoke(() -> verifyReceiverState(false));
 
     pause(10000);
-    String command = CliStrings.START_GATEWAYRECEIVER + " --"
-        + CliStrings.START_GATEWAYRECEIVER__GROUP + "=RG1,RG2";
+    String command = CliStrings.START_GATEWAYRECEIVER + " --" + CliStrings.GROUP + "=RG1,RG2";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);

http://git-wip-us.apache.org/repos/asf/geode/blob/db8e1df3/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewayReceiverStopDUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewayReceiverStopDUnitTest.java b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewayReceiverStopDUnitTest.java
index 5d211b0..2cfc5db 100644
--- a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewayReceiverStopDUnitTest.java
+++ b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewayReceiverStopDUnitTest.java
@@ -48,22 +48,21 @@ public class WanCommandGatewayReceiverStopDUnitTest extends WANCommandTestBase {
   public void testStopGatewayReceiver_ErrorConditions() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createReceiver(punePort));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
 
-    String command =
-        CliStrings.STOP_GATEWAYRECEIVER + " --" + CliStrings.STOP_GATEWAYRECEIVER__MEMBER + "="
-            + vm1Member.getId() + " --" + CliStrings.STOP_GATEWAYRECEIVER__GROUP + "=RG1";
+    String command = CliStrings.STOP_GATEWAYRECEIVER + " --" + CliStrings.MEMBER + "="
+        + vm1Member.getId() + " --" + CliStrings.GROUP + "=RG1";
 
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
@@ -82,14 +81,14 @@ public class WanCommandGatewayReceiverStopDUnitTest extends WANCommandTestBase {
   public void testStopGatewayReceiver() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createAndStartReceiver(punePort));
     vm4.invoke(() -> createAndStartReceiver(punePort));
@@ -127,14 +126,14 @@ public class WanCommandGatewayReceiverStopDUnitTest extends WANCommandTestBase {
   public void testStopGatewayReceiver_onMember() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createAndStartReceiver(punePort));
     vm4.invoke(() -> createAndStartReceiver(punePort));
@@ -144,10 +143,10 @@ public class WanCommandGatewayReceiverStopDUnitTest extends WANCommandTestBase {
     vm4.invoke(() -> verifyReceiverState(true));
     vm5.invoke(() -> verifyReceiverState(true));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
     pause(10000);
-    String command = CliStrings.STOP_GATEWAYRECEIVER + " --"
-        + CliStrings.STOP_GATEWAYRECEIVER__MEMBER + "=" + vm1Member.getId();
+    String command =
+        CliStrings.STOP_GATEWAYRECEIVER + " --" + CliStrings.MEMBER + "=" + vm1Member.getId();
 
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
@@ -172,14 +171,14 @@ public class WanCommandGatewayReceiverStopDUnitTest extends WANCommandTestBase {
   public void testStopGatewayReceiver_Group() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createAndStartReceiverWithGroup(punePort, "RG1"));
     vm4.invoke(() -> createAndStartReceiverWithGroup(punePort, "RG1"));
@@ -190,8 +189,7 @@ public class WanCommandGatewayReceiverStopDUnitTest extends WANCommandTestBase {
     vm5.invoke(() -> verifyReceiverState(true));
 
     pause(10000);
-    String command =
-        CliStrings.STOP_GATEWAYRECEIVER + " --" + CliStrings.STOP_GATEWAYRECEIVER__GROUP + "=RG1";
+    String command = CliStrings.STOP_GATEWAYRECEIVER + " --" + CliStrings.GROUP + "=RG1";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -221,14 +219,14 @@ public class WanCommandGatewayReceiverStopDUnitTest extends WANCommandTestBase {
   public void testStopGatewayReceiver_MultipleGroup() {
 
     VM puneLocator = Host.getLocator();
-    int punePort = (Integer) puneLocator.invoke(() -> getLocatorPort());
+    int punePort = puneLocator.invoke(() -> getLocatorPort());
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createAndStartReceiverWithGroup(punePort, "RG1"));
     vm4.invoke(() -> createAndStartReceiverWithGroup(punePort, "RG1"));
@@ -243,8 +241,7 @@ public class WanCommandGatewayReceiverStopDUnitTest extends WANCommandTestBase {
     vm7.invoke(() -> verifyReceiverState(true));
 
     pause(10000);
-    String command = CliStrings.STOP_GATEWAYRECEIVER + " --"
-        + CliStrings.STOP_GATEWAYRECEIVER__GROUP + "=RG1,RG2";
+    String command = CliStrings.STOP_GATEWAYRECEIVER + " --" + CliStrings.GROUP + "=RG1,RG2";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);

http://git-wip-us.apache.org/repos/asf/geode/blob/db8e1df3/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewaySenderStartDUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewaySenderStartDUnitTest.java b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewaySenderStartDUnitTest.java
index db1de4b..a77c499 100644
--- a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewaySenderStartDUnitTest.java
+++ b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewaySenderStartDUnitTest.java
@@ -44,7 +44,7 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
   @Test
   public void testStartGatewaySender_ErrorConditions() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -52,16 +52,16 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
 
     String command = CliStrings.START_GATEWAYSENDER + " --" + CliStrings.START_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.START_GATEWAYSENDER__MEMBER + "=" + vm1Member.getId() + " --"
-        + CliStrings.START_GATEWAYSENDER__GROUP + "=SenserGroup1";
+        + "=ln --" + CliStrings.MEMBER + "=" + vm1Member.getId() + " --" + CliStrings.GROUP
+        + "=SenserGroup1";
     CommandResult cmdResult = executeCommandWithIgnoredExceptions(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -86,7 +86,7 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
   @Test
   public void testStartGatewaySender() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -94,7 +94,7 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -136,7 +136,7 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
   @Test
   public void testStartGatewaySender_onMember() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -144,17 +144,17 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
 
     vm3.invoke(() -> verifySenderState("ln", false, false));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
     pause(10000);
     String command = CliStrings.START_GATEWAYSENDER + " --" + CliStrings.START_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.START_GATEWAYSENDER__MEMBER + "=" + vm1Member.getId();
+        + "=ln --" + CliStrings.MEMBER + "=" + vm1Member.getId();
     CommandResult cmdResult = executeCommandWithIgnoredExceptions(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -174,7 +174,7 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
   @Test
   public void testStartGatewaySender_Group() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -182,7 +182,7 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCacheWithGroups(punePort, "SenderGroup1"));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -197,7 +197,7 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
 
     pause(10000);
     String command = CliStrings.START_GATEWAYSENDER + " --" + CliStrings.START_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.START_GATEWAYSENDER__GROUP + "=SenderGroup1";
+        + "=ln --" + CliStrings.GROUP + "=SenderGroup1";
     CommandResult cmdResult = executeCommandWithIgnoredExceptions(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -225,7 +225,7 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
   @Test
   public void testStartGatewaySender_MultipleGroup() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -233,7 +233,7 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCacheWithGroups(punePort, "SenderGroup1"));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -254,7 +254,7 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
 
     pause(10000);
     String command = CliStrings.START_GATEWAYSENDER + " --" + CliStrings.START_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.START_GATEWAYSENDER__GROUP + "=SenderGroup1,SenderGroup2";
+        + "=ln --" + CliStrings.GROUP + "=SenderGroup1,SenderGroup2";
     CommandResult cmdResult = executeCommandWithIgnoredExceptions(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -282,7 +282,7 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
   @Test
   public void testStartGatewaySender_Group_MissingSenderFromGroup() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -290,7 +290,7 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCacheWithGroups(punePort, "SenderGroup1"));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -303,7 +303,7 @@ public class WanCommandGatewaySenderStartDUnitTest extends WANCommandTestBase {
 
     pause(10000);
     String command = CliStrings.START_GATEWAYSENDER + " --" + CliStrings.START_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.START_GATEWAYSENDER__GROUP + "=SenderGroup1";
+        + "=ln --" + CliStrings.GROUP + "=SenderGroup1";
     CommandResult cmdResult = executeCommandWithIgnoredExceptions(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);

http://git-wip-us.apache.org/repos/asf/geode/blob/db8e1df3/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewaySenderStopDUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewaySenderStopDUnitTest.java b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewaySenderStopDUnitTest.java
index a9d9cb4..1a4fa07 100644
--- a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewaySenderStopDUnitTest.java
+++ b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandGatewaySenderStopDUnitTest.java
@@ -47,7 +47,7 @@ public class WanCommandGatewaySenderStopDUnitTest extends WANCommandTestBase {
   @Test
   public void testStopGatewaySender_ErrorConditions() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -55,16 +55,16 @@ public class WanCommandGatewaySenderStopDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
 
     String command = CliStrings.STOP_GATEWAYSENDER + " --" + CliStrings.STOP_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.STOP_GATEWAYSENDER__MEMBER + "=" + vm1Member.getId() + " --"
-        + CliStrings.STOP_GATEWAYSENDER__GROUP + "=SenderGroup1";
+        + "=ln --" + CliStrings.MEMBER + "=" + vm1Member.getId() + " --" + CliStrings.GROUP
+        + "=SenderGroup1";
     CommandResult cmdResult = executeCommandWithIgnoredExceptions(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -79,7 +79,7 @@ public class WanCommandGatewaySenderStopDUnitTest extends WANCommandTestBase {
   @Test
   public void testStopGatewaySender() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -87,7 +87,7 @@ public class WanCommandGatewaySenderStopDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -133,7 +133,7 @@ public class WanCommandGatewaySenderStopDUnitTest extends WANCommandTestBase {
   @Test
   public void testStopGatewaySender_onMember() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -141,7 +141,7 @@ public class WanCommandGatewaySenderStopDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -150,10 +150,10 @@ public class WanCommandGatewaySenderStopDUnitTest extends WANCommandTestBase {
 
     vm3.invoke(() -> verifySenderState("ln", true, false));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
     pause(10000);
     String command = CliStrings.STOP_GATEWAYSENDER + " --" + CliStrings.STOP_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.STOP_GATEWAYSENDER__MEMBER + "=" + vm1Member.getId();
+        + "=ln --" + CliStrings.MEMBER + "=" + vm1Member.getId();
     CommandResult cmdResult = executeCommandWithIgnoredExceptions(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -173,7 +173,7 @@ public class WanCommandGatewaySenderStopDUnitTest extends WANCommandTestBase {
   @Test
   public void testStopGatewaySender_Group() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -181,7 +181,7 @@ public class WanCommandGatewaySenderStopDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCacheWithGroups(punePort, "SenderGroup1"));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -200,7 +200,7 @@ public class WanCommandGatewaySenderStopDUnitTest extends WANCommandTestBase {
 
     pause(10000);
     String command = CliStrings.STOP_GATEWAYSENDER + " --" + CliStrings.STOP_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.STOP_GATEWAYSENDER__GROUP + "=SenderGroup1";
+        + "=ln --" + CliStrings.GROUP + "=SenderGroup1";
     CommandResult cmdResult = executeCommandWithIgnoredExceptions(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -228,7 +228,7 @@ public class WanCommandGatewaySenderStopDUnitTest extends WANCommandTestBase {
   @Test
   public void testStopGatewaySender_MultipleGroup() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -236,7 +236,7 @@ public class WanCommandGatewaySenderStopDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCacheWithGroups(punePort, "SenderGroup1"));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -263,7 +263,7 @@ public class WanCommandGatewaySenderStopDUnitTest extends WANCommandTestBase {
 
     pause(10000);
     String command = CliStrings.STOP_GATEWAYSENDER + " --" + CliStrings.STOP_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.STOP_GATEWAYSENDER__GROUP + "=SenderGroup1,SenderGroup2";
+        + "=ln --" + CliStrings.GROUP + "=SenderGroup1,SenderGroup2";
     CommandResult cmdResult = executeCommandWithIgnoredExceptions(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);

http://git-wip-us.apache.org/repos/asf/geode/blob/db8e1df3/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandListDUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandListDUnitTest.java b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandListDUnitTest.java
index 8294d66..409c457 100644
--- a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandListDUnitTest.java
+++ b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandListDUnitTest.java
@@ -40,7 +40,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
   @Test
   public void testListGatewayWithNoSenderReceiver() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -48,7 +48,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm4.invoke(() -> createCache(punePort));
@@ -69,7 +69,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
   @Test
   public void testListGatewaySender() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -77,7 +77,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm6.invoke(() -> createAndStartReceiver(nyPort));
     vm7.invoke(() -> createAndStartReceiver(nyPort));
@@ -120,7 +120,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
   @Test
   public void testListGatewayReceiver() {
 
-    Integer lnPort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer lnPort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -128,7 +128,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + lnPort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
 
     vm3.invoke(() -> createAndStartReceiver(lnPort));
     vm4.invoke(() -> createAndStartReceiver(lnPort));
@@ -167,7 +167,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
   @Test
   public void testListGatewaySenderGatewayReceiver() throws GfJsonException {
 
-    Integer lnPort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer lnPort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -175,7 +175,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + lnPort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
 
     vm6.invoke(() -> createAndStartReceiver(nyPort));
 
@@ -227,7 +227,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
   @Test
   public void testListGatewaySenderGatewayReceiver_group() {
 
-    Integer lnPort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer lnPort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -235,7 +235,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + lnPort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
 
     vm6.invoke(() -> createAndStartReceiver(nyPort));
 
@@ -256,8 +256,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
     vm7.invoke(() -> createSender("ln_Parallel", 1, true, 100, 400, false, false, null, false));
 
     pause(10000);
-    String command =
-        CliStrings.LIST_GATEWAY + " --" + CliStrings.LIST_GATEWAY__GROUP + "=Serial_Sender";
+    String command = CliStrings.LIST_GATEWAY + " --" + CliStrings.GROUP + "=Serial_Sender";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -277,7 +276,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
       fail("testListGatewaySenderGatewayReceiver_group failed as did not get CommandResult");
     }
 
-    command = CliStrings.LIST_GATEWAY + " --" + CliStrings.LIST_GATEWAY__GROUP + "=Parallel_Sender";
+    command = CliStrings.LIST_GATEWAY + " --" + CliStrings.GROUP + "=Parallel_Sender";
     cmdResult = executeCommand(command);
     if (cmdResult != null) {
       TabularResultData tableSenderResultData = ((CompositeResultData) cmdResult.getResultData())
@@ -300,7 +299,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
       fail("testListGatewaySenderGatewayReceiver_group failed as did not get CommandResult");
     }
 
-    command = CliStrings.LIST_GATEWAY + " --" + CliStrings.LIST_GATEWAY__GROUP + "=Receiver_Group";
+    command = CliStrings.LIST_GATEWAY + " --" + CliStrings.GROUP + "=Receiver_Group";
     cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -324,8 +323,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
       fail("testListGatewaySenderGatewayReceiver_group failed as did not get CommandResult");
     }
 
-    command = CliStrings.LIST_GATEWAY + " --" + CliStrings.LIST_GATEWAY__GROUP
-        + "=Serial_Sender,Parallel_Sender";
+    command = CliStrings.LIST_GATEWAY + " --" + CliStrings.GROUP + "=Serial_Sender,Parallel_Sender";
     cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -348,7 +346,7 @@ public class WanCommandListDUnitTest extends WANCommandTestBase {
       fail("testListGatewaySenderGatewayReceiver_group failed as did not get CommandResult");
     }
 
-    command = CliStrings.LIST_GATEWAY + " --" + CliStrings.LIST_GATEWAY__GROUP
+    command = CliStrings.LIST_GATEWAY + " --" + CliStrings.GROUP
         + "=Serial_Sender,Parallel_Sender,Receiver_Group";
     cmdResult = executeCommand(command);
     if (cmdResult != null) {

http://git-wip-us.apache.org/repos/asf/geode/blob/db8e1df3/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandPauseResumeDUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandPauseResumeDUnitTest.java b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandPauseResumeDUnitTest.java
index 4b29d35..bae0553 100644
--- a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandPauseResumeDUnitTest.java
+++ b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandPauseResumeDUnitTest.java
@@ -39,7 +39,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
   @Test
   public void testPauseGatewaySender_ErrorConditions() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -47,16 +47,16 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
 
     String command = CliStrings.PAUSE_GATEWAYSENDER + " --" + CliStrings.PAUSE_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.PAUSE_GATEWAYSENDER__MEMBER + "=" + vm1Member.getId() + " --"
-        + CliStrings.PAUSE_GATEWAYSENDER__GROUP + "=SenderGroup1";
+        + "=ln --" + CliStrings.MEMBER + "=" + vm1Member.getId() + " --" + CliStrings.GROUP
+        + "=SenderGroup1";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -74,7 +74,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
   @Test
   public void testPauseGatewaySender_onMember() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -82,7 +82,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -91,10 +91,10 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
 
     vm3.invoke(() -> verifySenderState("ln", true, false));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
     pause(10000);
     String command = CliStrings.PAUSE_GATEWAYSENDER + " --" + CliStrings.PAUSE_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.PAUSE_GATEWAYSENDER__MEMBER + "=" + vm1Member.getId();
+        + "=ln --" + CliStrings.MEMBER + "=" + vm1Member.getId();
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -111,7 +111,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
   @Test
   public void testPauseGatewaySender() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -119,7 +119,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -165,7 +165,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
   @Test
   public void testPauseGatewaySender_Group() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -173,7 +173,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCacheWithGroups(punePort, "SenderGroup1"));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -192,7 +192,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
 
     pause(10000);
     String command = CliStrings.PAUSE_GATEWAYSENDER + " --" + CliStrings.PAUSE_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.PAUSE_GATEWAYSENDER__GROUP + "=SenderGroup1";
+        + "=ln --" + CliStrings.GROUP + "=SenderGroup1";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -220,7 +220,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
   @Test
   public void testPauseGatewaySender_MultipleGroup() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -228,7 +228,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCacheWithGroups(punePort, "SenderGroup1"));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -255,7 +255,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
 
     pause(10000);
     String command = CliStrings.PAUSE_GATEWAYSENDER + " --" + CliStrings.PAUSE_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.PAUSE_GATEWAYSENDER__GROUP + "=SenderGroup1,SenderGroup2";
+        + "=ln --" + CliStrings.GROUP + "=SenderGroup1,SenderGroup2";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -280,7 +280,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
   @Test
   public void testResumeGatewaySender_ErrorConditions() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -288,16 +288,16 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
 
     String command = CliStrings.RESUME_GATEWAYSENDER + " --" + CliStrings.RESUME_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.RESUME_GATEWAYSENDER__MEMBER + "=" + vm1Member.getId() + " --"
-        + CliStrings.RESUME_GATEWAYSENDER__GROUP + "=SenderGroup1";
+        + "=ln --" + CliStrings.MEMBER + "=" + vm1Member.getId() + " --" + CliStrings.GROUP
+        + "=SenderGroup1";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -313,7 +313,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
   @Test
   public void testResumeGatewaySender() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -321,7 +321,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -375,7 +375,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
   @Test
   public void testResumeGatewaySender_onMember() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -383,7 +383,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCache(punePort));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -396,10 +396,10 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
 
     vm3.invoke(() -> verifySenderState("ln", true, true));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
     pause(10000);
     String command = CliStrings.RESUME_GATEWAYSENDER + " --" + CliStrings.RESUME_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.RESUME_GATEWAYSENDER__MEMBER + "=" + vm1Member.getId();
+        + "=ln --" + CliStrings.MEMBER + "=" + vm1Member.getId();
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -419,7 +419,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
   @Test
   public void testResumeGatewaySender_Group() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -427,7 +427,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCacheWithGroups(punePort, "SenderGroup1"));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -454,7 +454,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
 
     pause(10000);
     String command = CliStrings.RESUME_GATEWAYSENDER + " --" + CliStrings.RESUME_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.RESUME_GATEWAYSENDER__GROUP + "=SenderGroup1";
+        + "=ln --" + CliStrings.GROUP + "=SenderGroup1";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);
@@ -482,7 +482,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
   @Test
   public void testResumeGatewaySender_MultipleGroup() {
 
-    Integer punePort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer punePort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
@@ -490,7 +490,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
     props.setProperty(LOCATORS, "localhost[" + punePort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, punePort));
 
     vm3.invoke(() -> createCacheWithGroups(punePort, "SenderGroup1"));
     vm3.invoke(() -> createSender("ln", 2, false, 100, 400, false, false, null, true));
@@ -529,7 +529,7 @@ public class WanCommandPauseResumeDUnitTest extends WANCommandTestBase {
 
     pause(10000);
     String command = CliStrings.RESUME_GATEWAYSENDER + " --" + CliStrings.RESUME_GATEWAYSENDER__ID
-        + "=ln --" + CliStrings.RESUME_GATEWAYSENDER__GROUP + "=SenderGroup1,SenderGroup2";
+        + "=ln --" + CliStrings.GROUP + "=SenderGroup1,SenderGroup2";
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
       String strCmdResult = commandResultToString(cmdResult);

http://git-wip-us.apache.org/repos/asf/geode/blob/db8e1df3/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandStatusDUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandStatusDUnitTest.java b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandStatusDUnitTest.java
index 5b127d0..d067bad 100644
--- a/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandStatusDUnitTest.java
+++ b/geode-wan/src/test/java/org/apache/geode/internal/cache/wan/wancommand/WanCommandStatusDUnitTest.java
@@ -42,14 +42,14 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
   @Test
   public void testGatewaySenderStatus() {
 
-    Integer lnPort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer lnPort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + lnPort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
 
     vm6.invoke(() -> createAndStartReceiver(nyPort));
 
@@ -128,14 +128,14 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
   @Test
   public void testGatewaySenderStatus_OnMember() {
 
-    Integer lnPort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer lnPort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + lnPort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
 
     vm6.invoke(() -> createAndStartReceiver(nyPort));
 
@@ -149,11 +149,11 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
 
     vm5.invoke(() -> createCache(lnPort));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
 
     pause(10000);
     String command = CliStrings.STATUS_GATEWAYSENDER + " --" + CliStrings.STATUS_GATEWAYSENDER__ID
-        + "=ln_Serial --" + CliStrings.STATUS_GATEWAYSENDER__MEMBER + "=" + vm1Member.getId();
+        + "=ln_Serial --" + CliStrings.MEMBER + "=" + vm1Member.getId();
 
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
@@ -180,7 +180,7 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
 
     pause(10000);
     command = CliStrings.STATUS_GATEWAYSENDER + " --" + CliStrings.STATUS_GATEWAYSENDER__ID
-        + "=ln_Serial --" + CliStrings.STATUS_GATEWAYSENDER__MEMBER + "=" + vm1Member.getId();
+        + "=ln_Serial --" + CliStrings.MEMBER + "=" + vm1Member.getId();
 
     cmdResult = executeCommand(command);
     if (cmdResult != null) {
@@ -203,10 +203,10 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
       fail("testListGatewaySender failed as did not get CommandResult");
     }
 
-    final DistributedMember vm5Member = (DistributedMember) vm5.invoke(() -> getMember());
+    final DistributedMember vm5Member = vm5.invoke(() -> getMember());
 
     command = CliStrings.STATUS_GATEWAYSENDER + " --" + CliStrings.STATUS_GATEWAYSENDER__ID
-        + "=ln_Serial --" + CliStrings.STATUS_GATEWAYSENDER__MEMBER + "=" + vm5Member.getId();
+        + "=ln_Serial --" + CliStrings.MEMBER + "=" + vm5Member.getId();
     cmdResult = executeCommand(command);
     if (cmdResult != null) {
       // ErrorResultData errorResultData =
@@ -224,14 +224,14 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
   @Test
   public void testGatewaySenderStatus_OnGroups() {
 
-    Integer lnPort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer lnPort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + lnPort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
 
     vm7.invoke(() -> createAndStartReceiver(nyPort));
 
@@ -249,11 +249,11 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
 
     vm6.invoke(() -> createCacheWithGroups(lnPort, "Serial_Sender"));
 
-    final DistributedMember vm1Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm1Member = vm3.invoke(() -> getMember());
 
     pause(10000);
     String command = CliStrings.STATUS_GATEWAYSENDER + " --" + CliStrings.STATUS_GATEWAYSENDER__ID
-        + "=ln_Serial --" + CliStrings.STATUS_GATEWAYSENDER__GROUP + "=Serial_Sender";
+        + "=ln_Serial --" + CliStrings.GROUP + "=Serial_Sender";
 
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
@@ -286,7 +286,7 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
 
     pause(10000);
     command = CliStrings.STATUS_GATEWAYSENDER + " --" + CliStrings.STATUS_GATEWAYSENDER__ID
-        + "=ln_Serial --" + CliStrings.STATUS_GATEWAYSENDER__GROUP + "=Serial_Sender";
+        + "=ln_Serial --" + CliStrings.GROUP + "=Serial_Sender";
 
     cmdResult = executeCommand(command);
     if (cmdResult != null) {
@@ -314,14 +314,14 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
   @Test
   public void testGatewayReceiverStatus() {
 
-    Integer lnPort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer lnPort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + lnPort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
 
     vm6.invoke(() -> createAndStartReceiver(nyPort));
 
@@ -394,14 +394,14 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
   @Test
   public void testGatewayReceiverStatus_OnMember() {
 
-    Integer lnPort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer lnPort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + lnPort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
 
     vm6.invoke(() -> createAndStartReceiver(nyPort));
 
@@ -409,11 +409,11 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
     vm4.invoke(() -> createAndStartReceiver(lnPort));
     vm5.invoke(() -> createAndStartReceiver(lnPort));
 
-    final DistributedMember vm3Member = (DistributedMember) vm3.invoke(() -> getMember());
+    final DistributedMember vm3Member = vm3.invoke(() -> getMember());
 
     pause(10000);
-    String command = CliStrings.STATUS_GATEWAYRECEIVER + " --"
-        + CliStrings.STATUS_GATEWAYRECEIVER__MEMBER + "=" + vm3Member.getId();
+    String command =
+        CliStrings.STATUS_GATEWAYRECEIVER + " --" + CliStrings.MEMBER + "=" + vm3Member.getId();
 
     CommandResult cmdResult = executeCommand(command);
 
@@ -441,8 +441,8 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
 
     pause(10000);
 
-    command = CliStrings.STATUS_GATEWAYRECEIVER + " --" + CliStrings.STATUS_GATEWAYRECEIVER__MEMBER
-        + "=" + vm3Member.getId();
+    command =
+        CliStrings.STATUS_GATEWAYRECEIVER + " --" + CliStrings.MEMBER + "=" + vm3Member.getId();
 
     cmdResult = executeCommand(command);
     if (cmdResult != null) {
@@ -469,14 +469,14 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
   @Test
   public void testGatewayReceiverStatus_OnGroups() {
 
-    Integer lnPort = (Integer) vm1.invoke(() -> createFirstLocatorWithDSId(1));
+    Integer lnPort = vm1.invoke(() -> createFirstLocatorWithDSId(1));
 
     Properties props = getDistributedSystemProperties();
     props.setProperty(MCAST_PORT, "0");
     props.setProperty(LOCATORS, "localhost[" + lnPort + "]");
     setUpJmxManagerOnVm0ThenConnect(props);
 
-    Integer nyPort = (Integer) vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
+    Integer nyPort = vm2.invoke(() -> createFirstRemoteLocator(2, lnPort));
 
     vm7.invoke(() -> createAndStartReceiver(nyPort));
 
@@ -486,8 +486,7 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
     vm6.invoke(() -> createAndStartReceiverWithGroup(lnPort, "RG2"));
 
     pause(10000);
-    String command = CliStrings.STATUS_GATEWAYRECEIVER + " --"
-        + CliStrings.STATUS_GATEWAYRECEIVER__GROUP + "=RG1";
+    String command = CliStrings.STATUS_GATEWAYRECEIVER + " --" + CliStrings.GROUP + "=RG1";
 
     CommandResult cmdResult = executeCommand(command);
     if (cmdResult != null) {
@@ -513,8 +512,7 @@ public class WanCommandStatusDUnitTest extends WANCommandTestBase {
     vm5.invoke(() -> stopReceiver());
 
     pause(10000);
-    command = CliStrings.STATUS_GATEWAYRECEIVER + " --" + CliStrings.STATUS_GATEWAYRECEIVER__GROUP
-        + "=RG1";
+    command = CliStrings.STATUS_GATEWAYRECEIVER + " --" + CliStrings.GROUP + "=RG1";
 
     cmdResult = executeCommand(command);
     if (cmdResult != null) {

http://git-wip-us.apache.org/repos/asf/geode/blob/db8e1df3/geode-wan/src/test/java/org/apache/geode/management/internal/configuration/ClusterConfigurationDUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-wan/src/test/java/org/apache/geode/management/internal/configuration/ClusterConfigurationDUnitTest.java b/geode-wan/src/test/java/org/apache/geode/management/internal/configuration/ClusterConfigurationDUnitTest.java
index b6b6712..9eb423f 100644
--- a/geode-wan/src/test/java/org/apache/geode/management/internal/configuration/ClusterConfigurationDUnitTest.java
+++ b/geode-wan/src/test/java/org/apache/geode/management/internal/configuration/ClusterConfigurationDUnitTest.java
@@ -166,8 +166,8 @@ public class ClusterConfigurationDUnitTest extends CliCommandTestBase {
       // MockCacheExtension verification
       @SuppressWarnings("unchecked")
       // should only be one cache extension
-      final MockCacheExtension mockCacheExtension = (MockCacheExtension) ((Extensible<Cache>) cache)
-          .getExtensionPoint().getExtensions().iterator().next();
+      final MockCacheExtension mockCacheExtension =
+          (MockCacheExtension) cache.getExtensionPoint().getExtensions().iterator().next();
       assertNotNull(mockCacheExtension);
       assertEquals(1, mockCacheExtension.beforeCreateCounter.get());
       assertEquals(1, mockCacheExtension.onCreateCounter.get());
@@ -231,7 +231,7 @@ public class ClusterConfigurationDUnitTest extends CliCommandTestBase {
 
       // MockCacheExtension verification
       @SuppressWarnings("unchecked")
-      final Extensible<Cache> extensibleCache = (Extensible<Cache>) cache;
+      final Extensible<Cache> extensibleCache = cache;
       // Should not be any cache extensions
       assertTrue(!extensibleCache.getExtensionPoint().getExtensions().iterator().hasNext());
 
@@ -344,7 +344,7 @@ public class ClusterConfigurationDUnitTest extends CliCommandTestBase {
         + "locator-" + locator1Port + ".log";
 
     VM locatorAndMgr = getHost(0).getVM(3);
-    Object[] result = (Object[]) locatorAndMgr.invoke(() -> {
+    Object[] result = locatorAndMgr.invoke(() -> {
       int httpPort;
       int jmxPort;
       String jmxHost;
@@ -433,7 +433,7 @@ public class ClusterConfigurationDUnitTest extends CliCommandTestBase {
     CommandStringBuilder csb = new CommandStringBuilder(CliStrings.CREATE_REGION);
     csb.addOption(CliStrings.CREATE_REGION__REGION, regionName);
     csb.addOption(CliStrings.CREATE_REGION__REGIONSHORTCUT, regionShortCut.name());
-    csb.addOptionWithValueCheck(CliStrings.CREATE_REGION__GROUP, group);
+    csb.addOptionWithValueCheck(CliStrings.GROUP, group);
     executeAndVerifyCommand(csb.toString());
   }
 

http://git-wip-us.apache.org/repos/asf/geode/blob/db8e1df3/geode-wan/src/test/java/org/apache/geode/management/internal/configuration/ClusterConfigurationIndexWithFromClauseDUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-wan/src/test/java/org/apache/geode/management/internal/configuration/ClusterConfigurationIndexWithFromClauseDUnitTest.java b/geode-wan/src/test/java/org/apache/geode/management/internal/configuration/ClusterConfigurationIndexWithFromClauseDUnitTest.java
index 5a15506..7e82d23 100644
--- a/geode-wan/src/test/java/org/apache/geode/management/internal/configuration/ClusterConfigurationIndexWithFromClauseDUnitTest.java
+++ b/geode-wan/src/test/java/org/apache/geode/management/internal/configuration/ClusterConfigurationIndexWithFromClauseDUnitTest.java
@@ -77,7 +77,7 @@ public class ClusterConfigurationIndexWithFromClauseDUnitTest {
     CommandStringBuilder csb = new CommandStringBuilder(CliStrings.LIST_MEMBER);
     gfshShellConnectionRule.executeAndVerifyCommand(csb.toString());
     lsRule.stopMember(1);
-    lsRule.startServerVM(1, lsRule.getMember(0).getPort());;
+    lsRule.startServerVM(1, lsRule.getMember(0).getPort());
     verifyIndexRecreated(INDEX_NAME);
   }
 
@@ -114,7 +114,7 @@ public class ClusterConfigurationIndexWithFromClauseDUnitTest {
     CommandStringBuilder csb = new CommandStringBuilder(CliStrings.CREATE_REGION);
     csb.addOption(CliStrings.CREATE_REGION__REGION, regionName);
     csb.addOption(CliStrings.CREATE_REGION__REGIONSHORTCUT, regionShortCut.name());
-    csb.addOptionWithValueCheck(CliStrings.CREATE_REGION__GROUP, group);
+    csb.addOptionWithValueCheck(CliStrings.GROUP, group);
     gfshShellConnectionRule.executeAndVerifyCommand(csb.toString());
   }
 }


Mime
View raw message