You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by sb...@apache.org on 2017/09/18 08:43:07 UTC
[07/26] ignite git commit: IGNITE-6368: Initial .NET part of thin
client. This closes #2670.
http://git-wip-us.apache.org/repos/asf/ignite/blob/a00052e9/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Deployment/PeerAssemblyResolver.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Deployment/PeerAssemblyResolver.cs b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Deployment/PeerAssemblyResolver.cs
index e22e325..a9e07d9 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Deployment/PeerAssemblyResolver.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Deployment/PeerAssemblyResolver.cs
@@ -147,9 +147,9 @@ namespace Apache.Ignite.Core.Impl.Deployment
var func = new GetAssemblyFunc();
var req = new AssemblyRequest(assemblyName);
- foreach (var node in GetDotNetNodes(ignite, originNodeId))
+ foreach (var node in GetDotNetNodes(ignite.GetIgnite(), originNodeId))
{
- var compute = ignite.GetCluster().ForNodeIds(node).GetCompute();
+ var compute = ignite.GetIgnite().GetCluster().ForNodeIds(node).GetCompute();
var result = ComputeApplySafe(compute, func, req);
if (result != null)
http://git-wip-us.apache.org/repos/asf/ignite/blob/a00052e9/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Deployment/PeerLoadingObjectHolder.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Deployment/PeerLoadingObjectHolder.cs b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Deployment/PeerLoadingObjectHolder.cs
index c3546bc..21aa4fb 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Deployment/PeerLoadingObjectHolder.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Deployment/PeerLoadingObjectHolder.cs
@@ -82,7 +82,7 @@ namespace Apache.Ignite.Core.Impl.Deployment
{
var writer0 = (BinaryWriter) writer.GetRawWriter();
- writer0.WriteGuid(writer0.Marshaller.Ignite.GetCluster().GetLocalNode().Id);
+ writer0.WriteGuid(writer0.Marshaller.Ignite.GetIgnite().GetCluster().GetLocalNode().Id);
writer0.WriteString(_object.GetType().AssemblyQualifiedName);
writer0.WriteObjectDetached(_object);
}
http://git-wip-us.apache.org/repos/asf/ignite/blob/a00052e9/modules/platforms/dotnet/Apache.Ignite.Core/Impl/ExceptionUtils.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/ExceptionUtils.cs b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/ExceptionUtils.cs
index 14ba666..aa28073 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/ExceptionUtils.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/ExceptionUtils.cs
@@ -139,10 +139,11 @@ namespace Apache.Ignite.Core.Impl
if (match.Success && Exs.TryGetValue(match.Groups[1].Value, out innerCtor))
{
return ctor(clsName, msg,
- innerCtor(match.Groups[1].Value, match.Groups[2].Value, innerException, ignite), ignite);
+ innerCtor(match.Groups[1].Value, match.Groups[2].Value, innerException, ignite.GetIgnite()),
+ ignite.GetIgnite());
}
- return ctor(clsName, msg, innerException, ignite);
+ return ctor(clsName, msg, innerException, ignite.GetIgnite());
}
if (ClsNoClsDefFoundErr.Equals(clsName, StringComparison.OrdinalIgnoreCase))
@@ -163,7 +164,7 @@ namespace Apache.Ignite.Core.Impl
if (ctor != null)
{
- return ctor(clsName, msg, innerException, ignite);
+ return ctor(clsName, msg, innerException, ignite.GetIgnite());
}
}
http://git-wip-us.apache.org/repos/asf/ignite/blob/a00052e9/modules/platforms/dotnet/Apache.Ignite.Core/Impl/IIgniteInternal.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/IIgniteInternal.cs b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/IIgniteInternal.cs
index 5fd6faa..c2169ed 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/IIgniteInternal.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/IIgniteInternal.cs
@@ -18,6 +18,7 @@
namespace Apache.Ignite.Core.Impl
{
using System;
+ using Apache.Ignite.Core.Binary;
using Apache.Ignite.Core.Datastream;
using Apache.Ignite.Core.Impl.Binary;
using Apache.Ignite.Core.Impl.Cluster;
@@ -27,7 +28,7 @@ namespace Apache.Ignite.Core.Impl
/// <summary>
/// Internal Ignite interface.
/// </summary>
- internal interface IIgniteInternal : IIgnite
+ internal interface IIgniteInternal
{
/// <summary>
/// Gets the binary processor.
@@ -65,5 +66,15 @@ namespace Apache.Ignite.Core.Impl
/// Gets the data streamer.
/// </summary>
IDataStreamer<TK, TV> GetDataStreamer<TK, TV>(string cacheName, bool keepBinary);
+
+ /// <summary>
+ /// Gets the public Ignite API.
+ /// </summary>
+ IIgnite GetIgnite();
+
+ /// <summary>
+ /// Gets the binary API.
+ /// </summary>
+ IBinary GetBinary();
}
}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/ignite/blob/a00052e9/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Ignite.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Ignite.cs b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Ignite.cs
index 59dfe2a..1b42462 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Ignite.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Ignite.cs
@@ -55,7 +55,7 @@ namespace Apache.Ignite.Core.Impl
/// <summary>
/// Native Ignite wrapper.
/// </summary>
- internal class Ignite : PlatformTargetAdapter, ICluster, IIgniteInternal
+ internal class Ignite : PlatformTargetAdapter, ICluster, IIgniteInternal, IIgnite
{
/// <summary>
/// Operation codes for PlatformProcessorImpl calls.
@@ -579,6 +579,14 @@ namespace Apache.Ignite.Core.Impl
return new DataStreamerImpl<TK, TV>(streamerTarget, _marsh, cacheName, keepBinary);
}
+ /// <summary>
+ /// Gets the public Ignite interface.
+ /// </summary>
+ public IIgnite GetIgnite()
+ {
+ return this;
+ }
+
/** <inheritdoc /> */
public IBinary GetBinary()
{