geode-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kl...@apache.org
Subject [21/50] [abbrv] incubator-geode git commit: fixing GEODE-588 CI Failure: LocatorDUnitTest.testMultipleMcastLocators
Date Tue, 01 Dec 2015 22:21:45 GMT
fixing GEODE-588 CI Failure: LocatorDUnitTest.testMultipleMcastLocators

forcing JGroups to use an IPv4 address for multicast unless the
PreferIPv6Addresses property is set to true.  Use of multicast is
also restricted to cache operations on regions with multicast enabled.
This avoids problems when multicast isn't properly set up and a user
enables use of multicast in the DistributedSystem config.


Project: http://git-wip-us.apache.org/repos/asf/incubator-geode/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-geode/commit/e3d5ebe1
Tree: http://git-wip-us.apache.org/repos/asf/incubator-geode/tree/e3d5ebe1
Diff: http://git-wip-us.apache.org/repos/asf/incubator-geode/diff/e3d5ebe1

Branch: refs/heads/feature/GEODE-291
Commit: e3d5ebe11422f6245e3f4ee4a86ce76e60c57bef
Parents: c0d396a
Author: Bruce Schuchardt <bschuchardt@pivotal.io>
Authored: Tue Nov 24 09:00:22 2015 -0800
Committer: Bruce Schuchardt <bschuchardt@pivotal.io>
Committed: Tue Nov 24 09:00:22 2015 -0800

----------------------------------------------------------------------
 .../gemfire/distributed/internal/DistributionManager.java   | 2 +-
 .../distributed/internal/InternalDistributedSystem.java     | 8 +++++---
 .../internal/membership/gms/messenger/JGroupsMessenger.java | 9 ++++-----
 .../gemstone/gemfire/internal/cache/GemFireCacheImpl.java   | 4 ----
 4 files changed, 10 insertions(+), 13 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/e3d5ebe1/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/DistributionManager.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/DistributionManager.java
b/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/DistributionManager.java
index 247775d..837194c 100644
--- a/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/DistributionManager.java
+++ b/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/DistributionManager.java
@@ -3383,7 +3383,7 @@ public class DistributionManager
     allOthers.remove(getDistributionManagerId());
 //    ReplyProcessor21 rp = new ReplyProcessor21(this, allOthers);
 //    m.setProcessorId(rp.getProcessorId());
-    m.setMulticast(system.getConfig().getMcastPort() != 0);
+//    m.setMulticast(system.getConfig().getMcastPort() != 0);
     m.setRecipients(allOthers);
 
     //Address recipient = (Address) m.getRecipient();

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/e3d5ebe1/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/InternalDistributedSystem.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/InternalDistributedSystem.java
b/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/InternalDistributedSystem.java
index 956fe8b..261b8a9 100644
--- a/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/InternalDistributedSystem.java
+++ b/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/InternalDistributedSystem.java
@@ -2578,10 +2578,12 @@ public final class InternalDistributedSystem
     
 //    logger.info("reconnecting IDS@"+System.identityHashCode(this));
 
-    if (isDebugEnabled) {
-      logger.debug("changing thread name to ReconnectThread");
+    if (Thread.currentThread().getName().equals("DisconnectThread")) {
+      if (isDebugEnabled) {
+        logger.debug("changing thread name to ReconnectThread");
+      }
+      Thread.currentThread().setName("ReconnectThread");
     }
-    Thread.currentThread().setName("ReconnectThread");
     
     // get the membership manager for quorum checks
     MembershipManager mbrMgr = this.dm.getMembershipManager();

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/e3d5ebe1/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/membership/gms/messenger/JGroupsMessenger.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/membership/gms/messenger/JGroupsMessenger.java
b/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/membership/gms/messenger/JGroupsMessenger.java
index 8ac8f77..889795d 100755
--- a/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/membership/gms/messenger/JGroupsMessenger.java
+++ b/gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/membership/gms/messenger/JGroupsMessenger.java
@@ -276,7 +276,7 @@ public class JGroupsMessenger implements Messenger {
       else {
         logger.debug("JGroups configuration: {}", properties);
         
-        checkForWindowsIPv6();
+        checkForIPv6();
         InputStream is = new ByteArrayInputStream(properties.getBytes("UTF-8"));
         myChannel = new JChannel(is);
       }
@@ -320,11 +320,10 @@ public class JGroupsMessenger implements Messenger {
    * and preferIPv6Addresses is not set or is true.  We want it to use an
    * IPv4 address for a dual-IP stack so that both IPv4 and IPv6 messaging work
    */
-  private void checkForWindowsIPv6() throws Exception {
-    boolean isWindows = ((String)System.getProperty("os.name")).indexOf("Windows") >=
0;
+  private void checkForIPv6() throws Exception {
     boolean preferIpV6Addr = Boolean.getBoolean("java.net.preferIPv6Addresses");
-    if (isWindows && !preferIpV6Addr) {
-      logger.debug("Windows detected - forcing JGroups to think IPv4 is being used so it
will choose an IPv4 address");
+    if (!preferIpV6Addr) {
+      logger.debug("forcing JGroups to think IPv4 is being used so it will choose an IPv4
address");
       Field m = org.jgroups.util.Util.class.getDeclaredField("ip_stack_type");
       m.setAccessible(true);
       m.set(null, org.jgroups.util.StackType.IPv4);

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/e3d5ebe1/gemfire-core/src/main/java/com/gemstone/gemfire/internal/cache/GemFireCacheImpl.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/main/java/com/gemstone/gemfire/internal/cache/GemFireCacheImpl.java
b/gemfire-core/src/main/java/com/gemstone/gemfire/internal/cache/GemFireCacheImpl.java
index cd7376d..27bb813 100644
--- a/gemfire-core/src/main/java/com/gemstone/gemfire/internal/cache/GemFireCacheImpl.java
+++ b/gemfire-core/src/main/java/com/gemstone/gemfire/internal/cache/GemFireCacheImpl.java
@@ -2205,10 +2205,6 @@ public class GemFireCacheImpl implements InternalCache, ClientCache,
HasCachePer
             Set otherMembers = dm.getOtherDistributionManagerIds();
             ReplyProcessor21 processor = new ReplyProcessor21(system, otherMembers);
             CloseCacheMessage msg = new CloseCacheMessage();
-            // [bruce] if multicast is available, use it to send the message to
-            // avoid race conditions with cache content operations that might
-            // also be multicast
-            msg.setMulticast(system.getConfig().getMcastPort() != 0);
             msg.setRecipients(otherMembers);
             msg.setProcessorId(processor.getProcessorId());
             dm.putOutgoing(msg);


Mime
View raw message