ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject [02/11] incubator-ignite git commit: # IGNITE-709 Bug fix: check (joinTimeout > 0)
Date Tue, 19 May 2015 19:39:54 GMT
# IGNITE-709 Bug fix: check (joinTimeout > 0)


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

Branch: refs/heads/ignite-23
Commit: f265cb68d108d5b3617f5d6f893f477ca2308bff
Parents: 9bbc1fe
Author: sevdokimov <sevdokimov@gridgain.com>
Authored: Mon May 18 17:14:23 2015 +0300
Committer: sevdokimov <sevdokimov@gridgain.com>
Committed: Mon May 18 17:14:23 2015 +0300

----------------------------------------------------------------------
 .../apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpi.java   | 4 ++--
 .../apache/ignite/spi/discovery/tcp/TcpDiscoverySpiAdapter.java  | 1 -
 2 files changed, 2 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/f265cb68/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpi.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpi.java
b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpi.java
index 6062ce5..5573f51 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpi.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpi.java
@@ -507,7 +507,7 @@ public class TcpClientDiscoverySpi extends TcpDiscoverySpiAdapter implements
Tcp
                 else {
                     U.warn(log, "No addresses registered in the IP finder (will retry in
2000ms): " + ipFinder);
 
-                    if ((U.currentTimeMillis() - startTime) > joinTimeout)
+                    if (joinTimeout > 0 && (U.currentTimeMillis() - startTime)
> joinTimeout)
                         return null;
 
                     Thread.sleep(2000);
@@ -581,7 +581,7 @@ public class TcpClientDiscoverySpi extends TcpDiscoverySpiAdapter implements
Tcp
                 U.warn(log, "Failed to connect to any address from IP finder (will retry
to join topology " +
                     "in 2000ms): " + addrs0);
 
-                if ((U.currentTimeMillis() - startTime) > joinTimeout)
+                if (joinTimeout > 0 && (U.currentTimeMillis() - startTime) >
joinTimeout)
                     return null;
 
                 Thread.sleep(2000);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/f265cb68/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpiAdapter.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpiAdapter.java
b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpiAdapter.java
index 3c3b984..a89dbcc 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpiAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpiAdapter.java
@@ -150,7 +150,6 @@ abstract class TcpDiscoverySpiAdapter extends IgniteSpiAdapter implements
Discov
         assertParameter(netTimeout > 0, "networkTimeout > 0");
         assertParameter(sockTimeout > 0, "sockTimeout > 0");
         assertParameter(ackTimeout > 0, "ackTimeout > 0");
-        assertParameter(joinTimeout >= 0, "joinTimeout >= 0");
     }
 
     /**


Mime
View raw message