You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by vo...@apache.org on 2016/09/08 14:46:24 UTC

[42/50] ignite git commit: Fix SessionStateLockResult registration

Fix SessionStateLockResult registration


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

Branch: refs/heads/ignite-3199-1
Commit: 595dd2ef1483a8639767188b0f8bbcac8e2e2b8a
Parents: ddae6ac
Author: Pavel Tupitsyn <pt...@apache.org>
Authored: Thu Sep 8 14:05:05 2016 +0300
Committer: Pavel Tupitsyn <pt...@apache.org>
Committed: Thu Sep 8 14:05:05 2016 +0300

----------------------------------------------------------------------
 .../org/apache/ignite/internal/binary/BinaryContext.java |  2 ++
 .../Impl/AspNet/SessionStateLockResult.cs                | 11 ++++++++++-
 .../dotnet/Apache.Ignite.Core/Impl/Binary/Marshaller.cs  |  1 +
 3 files changed, 13 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/595dd2ef/modules/core/src/main/java/org/apache/ignite/internal/binary/BinaryContext.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/binary/BinaryContext.java b/modules/core/src/main/java/org/apache/ignite/internal/binary/BinaryContext.java
index 49f1867..4e7fb7e 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/binary/BinaryContext.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/binary/BinaryContext.java
@@ -79,6 +79,7 @@ import org.apache.ignite.internal.processors.platform.PlatformJavaObjectFactoryP
 import org.apache.ignite.internal.processors.platform.websession.KeyValueDirtyTrackedCollection;
 import org.apache.ignite.internal.processors.platform.websession.SessionStateLockInfo;
 import org.apache.ignite.internal.processors.platform.websession.SessionStateData;
+import org.apache.ignite.internal.processors.platform.websession.SessionStateLockResult;
 import org.apache.ignite.internal.util.lang.GridMapEntry;
 import org.apache.ignite.internal.util.typedef.F;
 import org.apache.ignite.internal.util.typedef.T2;
@@ -323,6 +324,7 @@ public class BinaryContext {
 
         registerPredefinedType(SessionStateData.class, 0);
         registerPredefinedType(SessionStateLockInfo.class, 0);
+        registerPredefinedType(SessionStateLockResult.class, 0);
         registerPredefinedType(KeyValueDirtyTrackedCollection.class, 0);
 
         // IDs range [200..1000] is used by Ignite internal APIs.

http://git-wip-us.apache.org/repos/asf/ignite/blob/595dd2ef/modules/platforms/dotnet/Apache.Ignite.Core/Impl/AspNet/SessionStateLockResult.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/AspNet/SessionStateLockResult.cs b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/AspNet/SessionStateLockResult.cs
index 4bf483c..bab66f5 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/AspNet/SessionStateLockResult.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/AspNet/SessionStateLockResult.cs
@@ -20,11 +20,12 @@ namespace Apache.Ignite.Core.Impl.AspNet
     using System;
     using System.Diagnostics;
     using Apache.Ignite.Core.Binary;
+    using Apache.Ignite.Core.Impl.Binary;
 
     /// <summary>
     /// Result of the session state lock processor.
     /// </summary>
-    public class SessionStateLockResult
+    public class SessionStateLockResult : IBinaryWriteAware
     {
         /** Success flag. */
         private readonly bool _success;
@@ -80,5 +81,13 @@ namespace Apache.Ignite.Core.Impl.AspNet
         {
             return string.Format("{0} [Success={1}]", GetType().Name, _success);
         }
+
+        /// <summary>
+        /// Writes this object to the given writer.
+        /// </summary>
+        public void WriteBinary(IBinaryWriter writer)
+        {
+            throw new NotSupportedException(GetType() + " is only written from native code.");
+        }
     }
 }

http://git-wip-us.apache.org/repos/asf/ignite/blob/595dd2ef/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/Marshaller.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/Marshaller.cs b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/Marshaller.cs
index e7b345e..03dbe2f 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/Marshaller.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/Marshaller.cs
@@ -599,6 +599,7 @@ namespace Apache.Ignite.Core.Impl.Binary
             AddSystemType(0, r => new KeyValueDirtyTrackedCollection(r));
             AddSystemType(0, r => new SessionStateData(r));
             AddSystemType(0, r => new SessionStateLockInfo(r));
+            AddSystemType(0, r => new SessionStateLockResult(r));
         }
     }
 }