ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject [1/6] incubator-ignite git commit: IGNITE-250 Removed os, ent checking from TcpDiscoverySpi.
Date Sat, 14 Feb 2015 13:01:27 GMT
Repository: incubator-ignite
Updated Branches:
  refs/heads/sprint-1 306a4ed44 -> 188a18d55


IGNITE-250 Removed os, ent checking from TcpDiscoverySpi.


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

Branch: refs/heads/sprint-1
Commit: 2950a16a5d409340f28ff391e8486733dd38f778
Parents: 8d347ed
Author: nikolay_tikhonov <ntikhonov@gridgain.com>
Authored: Sat Feb 14 13:15:22 2015 +0300
Committer: nikolay_tikhonov <ntikhonov@gridgain.com>
Committed: Sat Feb 14 13:15:22 2015 +0300

----------------------------------------------------------------------
 .../spi/discovery/tcp/TcpDiscoverySpi.java      | 100 +------------------
 1 file changed, 5 insertions(+), 95 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2950a16a/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 ac2002e..cb1f1d1 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
@@ -3182,90 +3182,6 @@ public class TcpDiscoverySpi extends TcpDiscoverySpiAdapter implements
TcpDiscov
                 String rmtBuildVer = node.attribute(ATTR_BUILD_VER);
 
                 if (!F.eq(rmtBuildVer, locBuildVer)) {
-                    final String osFlag = "-os";
-                    final String entFlag = "-ent";
-
-                    assert locBuildVer.contains(osFlag) || locBuildVer.contains(entFlag);
-                    assert rmtBuildVer.contains(osFlag) || rmtBuildVer.contains(entFlag);
-
-                    // OS and ENT nodes cannot join one topology.
-                    if (locBuildVer.contains(entFlag) && rmtBuildVer.contains(osFlag)
||
-                        locBuildVer.contains(osFlag) && rmtBuildVer.contains(entFlag))
{
-                        String errMsg = "Topology cannot contain nodes of both enterprise
and open source " +
-                            "versions (node will not join, all nodes in topology should be
of either " +
-                            "enterprise or open source version) " +
-                            "[locBuildVer=" + locBuildVer + ", rmtBuildVer=" + rmtBuildVer
+
-                            ", locNodeAddrs=" + U.addressesAsString(locNode) +
-                            ", rmtNodeAddrs=" + U.addressesAsString(node) +
-                            ", locNodeId=" + locNode.id() + ", rmtNodeId=" + msg.creatorNodeId()
+ ']';
-
-                        LT.warn(log, null, errMsg);
-
-                        // Always output in debug.
-                        if (log.isDebugEnabled())
-                            log.debug(errMsg);
-
-                        try {
-                            String sndMsg = "Topology cannot contain nodes of both enterprise
and open source " +
-                                "versions (node will not join, all nodes in topology should
be of either " +
-                                "enterprise or open source version) " +
-                                "[locBuildVer=" + rmtBuildVer + ", rmtBuildVer=" + locBuildVer
+
-                                ", locNodeAddrs=" + U.addressesAsString(node) + ", locPort="
+ node.discoveryPort() +
-                                ", rmtNodeAddr=" + U.addressesAsString(locNode) + ", locNodeId="
+ node.id() +
-                                ", rmtNodeId=" + locNode.id() + ']';
-
-                            trySendMessageDirectly(node,
-                                new TcpDiscoveryCheckFailedMessage(locNodeId, sndMsg));
-                        }
-                        catch (IgniteSpiException e) {
-                            if (log.isDebugEnabled())
-                                log.debug("Failed to send version check failed message to
node " +
-                                    "[node=" + node + ", err=" + e.getMessage() + ']');
-                        }
-
-                        // Ignore join request.
-                        return;
-                    }
-
-                    // OS nodes don't support rolling updates.
-                    if (locBuildVer.contains(osFlag) && rmtBuildVer.contains(osFlag)
&&
-                        !locBuildVer.equals(rmtBuildVer)) {
-                        String errMsg = "Local node and remote node have different version
numbers " +
-                            "(node will not join, open source version does not support rolling
updates, " +
-                            "so versions must be exactly the same) " +
-                            "[locBuildVer=" + locBuildVer + ", rmtBuildVer=" + rmtBuildVer
+
-                            ", locNodeAddrs=" + U.addressesAsString(locNode) +
-                            ", rmtNodeAddrs=" + U.addressesAsString(node) +
-                            ", locNodeId=" + locNode.id() + ", rmtNodeId=" + msg.creatorNodeId()
+ ']';
-
-                        LT.warn(log, null, errMsg);
-
-                        // Always output in debug.
-                        if (log.isDebugEnabled())
-                            log.debug(errMsg);
-
-                        try {
-                            String sndMsg = "Local node and remote node have different version
numbers " +
-                                "(node will not join, open source version does not support
rolling updates, " +
-                                "so versions must be exactly the same) " +
-                                "[locBuildVer=" + rmtBuildVer + ", rmtBuildVer=" + locBuildVer
+
-                                ", locNodeAddrs=" + U.addressesAsString(node) + ", locPort="
+ node.discoveryPort() +
-                                ", rmtNodeAddr=" + U.addressesAsString(locNode) + ", locNodeId="
+ node.id() +
-                                ", rmtNodeId=" + locNode.id() + ']';
-
-                            trySendMessageDirectly(node,
-                                new TcpDiscoveryCheckFailedMessage(locNodeId, sndMsg));
-                        }
-                        catch (IgniteSpiException e) {
-                            if (log.isDebugEnabled())
-                                log.debug("Failed to send version check failed message to
node " +
-                                    "[node=" + node + ", err=" + e.getMessage() + ']');
-                        }
-
-                        // Ignore join request.
-                        return;
-                    }
-
                     Collection<String> locCompatibleVers = locNode.attribute(ATTR_COMPATIBLE_VERS);
                     Collection<String> rmtCompatibleVers = node.attribute(ATTR_COMPATIBLE_VERS);
 
@@ -3285,11 +3201,8 @@ public class TcpDiscoverySpi extends TcpDiscoverySpiAdapter implements
TcpDiscov
                     }
                     else {
                         String errMsg = "Local node's and remote node's build versions are
not compatible " +
-                            (rmtBuildVer.contains("-os") && locBuildVer.contains("-os")
?
-                                "(topologies built with different Ignite versions " +
-                                    "are supported in Enterprise version only) " :
-                                "(node will not join, all nodes in topology should have "
+
-                                    "compatible build versions) ") +
+                            "(topologies built with different Ignite versions " +
+                            "are supported in Enterprise version only) "  +
                             "[locBuildVer=" + locBuildVer + ", rmtBuildVer=" + rmtBuildVer
+
                             ", locNodeAddrs=" + U.addressesAsString(locNode) +
                             ", rmtNodeAddrs=" + U.addressesAsString(node) +
@@ -3303,12 +3216,9 @@ public class TcpDiscoverySpi extends TcpDiscoverySpiAdapter implements
TcpDiscov
 
                         try {
                             String sndMsg = "Local node's and remote node's build versions
are not compatible " +
-                                (rmtBuildVer.contains("-os") && locBuildVer.contains("-os")
?
-                                    "(topologies built with different Ignite versions " +
-                                        "are supported in Enterprise version only) " :
-                                    "(node will not join, all nodes in topology should have
" +
-                                        "compatible build versions) ") +
-                                "[locBuildVer=" + rmtBuildVer + ", rmtBuildVer=" + locBuildVer
+
+                                "(topologies built with different Ignite versions " +
+                                "are supported in Enterprise version only) " +
+                                " [locBuildVer=" + rmtBuildVer + ", rmtBuildVer=" + locBuildVer
+
                                 ", locNodeAddrs=" + U.addressesAsString(node) + ", locPort="
+ node.discoveryPort() +
                                 ", rmtNodeAddr=" + U.addressesAsString(locNode) + ", locNodeId="
+ node.id() +
                                 ", rmtNodeId=" + locNode.id() + ']';


Mime
View raw message