ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vkuliche...@apache.org
Subject [42/50] incubator-ignite git commit: sp-3
Date Thu, 02 Apr 2015 02:53:29 GMT
sp-3


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

Branch: refs/heads/ignite-471
Commit: 226887545372403f1042f163360e0ee9066e2a12
Parents: 6413426
Author: Yakov Zhdanov <yzhdanov@gridgain.com>
Authored: Wed Apr 1 17:44:38 2015 +0300
Committer: Yakov Zhdanov <yzhdanov@gridgain.com>
Committed: Wed Apr 1 17:44:38 2015 +0300

----------------------------------------------------------------------
 .../apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java    | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/22688754/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java
b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java
index 74a070f..d5c05f7 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java
@@ -1060,6 +1060,13 @@ public class TcpDiscoverySpi extends TcpDiscoverySpiAdapter implements
TcpDiscov
     }
 
     /**
+     * @return {@code True} if node is stopping.
+     */
+    private boolean isNodeStopping() {
+        return super.getSpiContext().isStopping();
+    }
+
+    /**
      * @throws IgniteSpiException If any error occurs.
      * @return {@code true} if IP finder contains local address.
      */
@@ -4695,7 +4702,7 @@ public class TcpDiscoverySpi extends TcpDiscoverySpiAdapter implements
TcpDiscov
 
                     // Ping.
                     if (msg instanceof TcpDiscoveryPingRequest) {
-                        if (ctxInitLatch.getCount() > 0 || !getSpiContext().isStopping())
{
+                        if (!isNodeStopping()) {
                             TcpDiscoveryPingRequest req = (TcpDiscoveryPingRequest)msg;
 
                             TcpDiscoveryPingResponse res = new TcpDiscoveryPingResponse(locNodeId);


Mime
View raw message