ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From amashen...@apache.org
Subject [ignite] 10/41: GG-17378: Port IGNITE-11787: Changed Affinity Awareness version to 1.4
Date Tue, 07 May 2019 15:21:18 GMT
This is an automated email from the ASF dual-hosted git repository.

amashenkov pushed a commit to branch gg-18540
in repository https://gitbox.apache.org/repos/asf/ignite.git

commit 9fdf9802db274902802bd2bacc6e5c52c889bcd3
Author: Igor Sapego <isapego@apache.org>
AuthorDate: Tue Apr 23 15:23:38 2019 +0300

    GG-17378: Port IGNITE-11787: Changed Affinity Awareness version to 1.4
    
    (cherry picked from commit d6827886a497b87a2449ee3c1b0a378501e7a9b7)
---
 .../processors/platform/client/ClientConnectionContext.java       | 8 ++++++--
 .../internal/processors/platform/client/ClientRequestHandler.java | 4 ++--
 .../internal/processors/platform/client/ClientResponse.java       | 4 ++--
 modules/platforms/cpp/thin-client/src/impl/data_channel.cpp       | 8 ++++----
 modules/platforms/cpp/thin-client/src/impl/data_channel.h         | 4 ++--
 modules/platforms/cpp/thin-client/src/impl/message.cpp            | 2 +-
 6 files changed, 17 insertions(+), 13 deletions(-)

diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/ClientConnectionContext.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/ClientConnectionContext.java
index 5d3171e..81e4bd8 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/ClientConnectionContext.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/ClientConnectionContext.java
@@ -45,14 +45,18 @@ public class ClientConnectionContext extends ClientListenerAbstractConnectionCon
     /** Version 1.2.0. */
     public static final ClientListenerProtocolVersion VER_1_2_0 = ClientListenerProtocolVersion.create(1,
2, 0);
 
-    /** Version 1.3.0. Added: Affinity Awareness support, IEP-23. */
+    /** Version 1.3.0. */
     public static final ClientListenerProtocolVersion VER_1_3_0 = ClientListenerProtocolVersion.create(1,
3, 0);
 
+    /** Version 1.4.0. Added: Affinity Awareness, IEP-23. */
+    public static final ClientListenerProtocolVersion VER_1_4_0 = ClientListenerProtocolVersion.create(1,
4, 0);
+
     /** Default version. */
-    public static final ClientListenerProtocolVersion DEFAULT_VER = VER_1_3_0;
+    public static final ClientListenerProtocolVersion DEFAULT_VER = VER_1_4_0;
 
     /** Supported versions. */
     private static final Collection<ClientListenerProtocolVersion> SUPPORTED_VERS =
Arrays.asList(
+        VER_1_4_0,
         VER_1_3_0,
         VER_1_2_0,
         VER_1_1_0,
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/ClientRequestHandler.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/ClientRequestHandler.java
index 4af438e..4d839ad 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/ClientRequestHandler.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/ClientRequestHandler.java
@@ -24,7 +24,7 @@ import org.apache.ignite.internal.processors.odbc.ClientListenerRequestHandler;
 import org.apache.ignite.internal.processors.odbc.ClientListenerResponse;
 import org.apache.ignite.plugin.security.SecurityException;
 
-import static org.apache.ignite.internal.processors.platform.client.ClientConnectionContext.VER_1_3_0;
+import static org.apache.ignite.internal.processors.platform.client.ClientConnectionContext.VER_1_4_0;
 
 /**
  * Thin client request handler.
@@ -83,7 +83,7 @@ public class ClientRequestHandler implements ClientListenerRequestHandler
{
     @Override public void writeHandshake(BinaryWriterExImpl writer) {
         writer.writeBoolean(true);
 
-        if (ver.compareTo(VER_1_3_0) >= 0) {
+        if (ver.compareTo(VER_1_4_0) >= 0) {
             writer.writeUuid(ctx.kernalContext().localNodeId());
         }
     }
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/ClientResponse.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/ClientResponse.java
index cef0d20..0f336b9 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/ClientResponse.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/ClientResponse.java
@@ -20,7 +20,7 @@ import org.apache.ignite.internal.binary.BinaryRawWriterEx;
 import org.apache.ignite.internal.processors.odbc.ClientListenerProtocolVersion;
 import org.apache.ignite.internal.processors.odbc.ClientListenerResponse;
 
-import static org.apache.ignite.internal.processors.platform.client.ClientConnectionContext.VER_1_3_0;
+import static org.apache.ignite.internal.processors.platform.client.ClientConnectionContext.VER_1_4_0;
 
 /**
  * Thin client response.
@@ -79,7 +79,7 @@ public class ClientResponse extends ClientListenerResponse {
 
         assert ver != null;
 
-        if (ver.compareTo(VER_1_3_0) >= 0) {
+        if (ver.compareTo(VER_1_4_0) >= 0) {
             boolean error = status() != ClientStatus.SUCCESS;
 
             short flags = ClientFlag.makeFlags(error, affinityVer.isChanged());
diff --git a/modules/platforms/cpp/thin-client/src/impl/data_channel.cpp b/modules/platforms/cpp/thin-client/src/impl/data_channel.cpp
index 7f8faac..aef57ca 100644
--- a/modules/platforms/cpp/thin-client/src/impl/data_channel.cpp
+++ b/modules/platforms/cpp/thin-client/src/impl/data_channel.cpp
@@ -30,11 +30,11 @@ namespace ignite
         namespace thin
         {
             const ProtocolVersion DataChannel::VERSION_1_2_0(1, 2, 0);
-            const ProtocolVersion DataChannel::VERSION_1_3_0(1, 3, 0);
-            const ProtocolVersion DataChannel::VERSION_DEFAULT(VERSION_1_3_0);
+            const ProtocolVersion DataChannel::VERSION_1_4_0(1, 4, 0);
+            const ProtocolVersion DataChannel::VERSION_DEFAULT(VERSION_1_4_0);
 
             DataChannel::VersionSet::value_type supportedArray[] = {
-                DataChannel::VERSION_1_3_0,
+                DataChannel::VERSION_1_4_0,
                 DataChannel::VERSION_1_2_0,
             };
 
@@ -322,7 +322,7 @@ namespace ignite
                     return false;
                 }
 
-                if (propVer >= VERSION_1_3_0)
+                if (propVer >= VERSION_1_4_0)
                 {
                     Guid nodeGuid = reader.ReadGuid();
 
diff --git a/modules/platforms/cpp/thin-client/src/impl/data_channel.h b/modules/platforms/cpp/thin-client/src/impl/data_channel.h
index 57ae1cc..8bd5f5c 100644
--- a/modules/platforms/cpp/thin-client/src/impl/data_channel.h
+++ b/modules/platforms/cpp/thin-client/src/impl/data_channel.h
@@ -59,8 +59,8 @@ namespace ignite
                 /** Version 1.2.0. */
                 static const ProtocolVersion VERSION_1_2_0;
                 
-                /** Version 1.3.0. Added: Best Effort Affinity support, IEP-23. */
-                static const ProtocolVersion VERSION_1_3_0;
+                /** Version 1.4.0. Added: Affinity Awareness support, IEP-23. */
+                static const ProtocolVersion VERSION_1_4_0;
 
                 /** Current version. */
                 static const ProtocolVersion VERSION_DEFAULT;
diff --git a/modules/platforms/cpp/thin-client/src/impl/message.cpp b/modules/platforms/cpp/thin-client/src/impl/message.cpp
index 8fe2fec..d1bf8f3 100644
--- a/modules/platforms/cpp/thin-client/src/impl/message.cpp
+++ b/modules/platforms/cpp/thin-client/src/impl/message.cpp
@@ -95,7 +95,7 @@ namespace ignite
 
             void Response::Read(binary::BinaryReaderImpl& reader, const ProtocolVersion&
ver)
             {
-                if (ver >= DataChannel::VERSION_1_3_0)
+                if (ver >= DataChannel::VERSION_1_4_0)
                 {
                     flags = reader.ReadInt16();
 


Mime
View raw message