Permalink
Browse files

Merge branch 'RemoteAPI_MetadataExchange'

  • Loading branch information...
Markus Zorn
Markus Zorn committed Nov 3, 2011
2 parents 34b670c + e6c4633 commit ad3a81832b978a9244a3af131afaccdb81cb5905
@@ -203,7 +203,7 @@ public virtual void OnCancelKeyPress(object sender, ConsoleCancelEventArgs e)
public void Run()
{
- GraphDSClient = new GraphDS_RemoteClient(new Uri("http://localhost:9970/rpc"), true);
+ GraphDSClient = new GraphDS_RemoteClient(new Uri("https://localhost:9970/rpc"), true);
SecToken = GraphDSClient.LogOn(new RemoteUserPasswordCredentials("test", "test"));
TransToken = GraphDSClient.BeginTransaction(SecToken);
@@ -235,7 +235,7 @@ public sonesGraphDBStartup(String[] myArgs)
Dictionary<string, object> RemoteAPIParameter = new Dictionary<string, object>();
RemoteAPIParameter.Add("IPAddress", IPAddress.Any);
RemoteAPIParameter.Add("Port", (ushort)9970);
- RemoteAPIParameter.Add("IsSecure", true);
+ //RemoteAPIParameter.Add("IsSecure", true);
_dsServer.StartService("sones.RemoteAPIService", RemoteAPIParameter);
#endregion
@@ -75,9 +75,9 @@ public GraphDS_RemoteClient(Uri myServiceAddress, bool myIsSecure = false)
try
{
- //not suitable for checking secured connections
+ //request to test connection
var Request = HttpWebRequest.Create(myServiceAddress.ToString());
- //var Response = Request.GetResponse();
+ var Response = Request.GetResponse();
}
catch (Exception ex)
{
@@ -85,9 +85,9 @@ public void Start(IDictionary<string, object> myStartParameter = null)
_RunningTime.Start();
_RPCServer = new sonesRPCServer(_GraphDS, Address, Port, UriPattern, _IsSecure);
_RPCServer.StartServiceHost();
- _description = " * RemoteAPI Service is started at " + ((_IsSecure == true) ? "https://" : "http://") + Address + ":" + Port + Environment.NewLine +
+ _description = " * RemoteAPI Service is started at " + _RPCServer.URI + Environment.NewLine +
" * web service definition can be found at " + Environment.NewLine +
- " " + ((_IsSecure == true) ? "https://" : "http://") + Address + ":" + Port + "/mex" + Environment.NewLine +
+ " " + _RPCServer.MexUri + "/wsdl" + Environment.NewLine +
" * default username and passwort: test / test ";
}
catch (Exception Ex)
@@ -109,7 +109,7 @@
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="RemoteAPIService.cs" />
<Compile Include="ServiceContractImplementation\StreamedService.cs" />
- <Compile Include="ServiceContracts\MonoMEX\MonoMEX.cs" />
+ <Compile Include="ServiceContracts\MEX\MonoMEX.cs" />
<Compile Include="ServiceContractImplementation\EdgeService.cs" />
<Compile Include="ServiceContractImplementation\EdgeTypeService.cs" />
<Compile Include="ServiceContractImplementation\GraphDS_API.cs" />
@@ -120,7 +120,7 @@
<Compile Include="ServiceContracts\EdgeInstanceService\IEdgeService.cs" />
<Compile Include="ServiceContracts\EdgeTypeServices\IEdgeTypeService.cs" />
<Compile Include="ServiceContracts\IRPCServiceContract.cs" />
- <Compile Include="ServiceContracts\MonoMEX\IMonoMEX.cs" />
+ <Compile Include="ServiceContracts\MEX\IMonoMEX.cs" />
<Compile Include="ServiceContracts\StreamedService\IStreamedService.cs" />
<Compile Include="ServiceContracts\VertexInstanceService\IVertexService.cs" />
<Compile Include="ServiceContracts\VertexTypeServices\IVertexTypeService.cs" />
@@ -189,7 +189,7 @@
<Folder Include="ServiceStatus\" />
</ItemGroup>
<ItemGroup>
- <EmbeddedResource Include="ServiceContracts\MonoMEX\WSDL.xml">
+ <EmbeddedResource Include="ServiceContracts\MEX\WSDL.xml">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</EmbeddedResource>
</ItemGroup>
@@ -6,7 +6,7 @@
using System.ServiceModel.Web;
using System.IO;
-namespace sones.GraphDS.Services.RemoteAPIService.ServiceContracts.MonoMEX
+namespace sones.GraphDS.Services.RemoteAPIService.ServiceContracts.MEX
{
[ServiceContract(Namespace = sonesRPCServer.Namespace)]
public interface IMonoMEX
@@ -31,7 +31,7 @@
using sones.GraphDS.Services.RemoteAPIService.ServiceContracts;
using sones.GraphDS.Services.RemoteAPIService.DataContracts;
using sones.Library.Commons.Security;
-using sones.GraphDS.Services.RemoteAPIService.ServiceContracts.MonoMEX;
+using sones.GraphDS.Services.RemoteAPIService.ServiceContracts.MEX;
using System.Reflection;
using System.IO;
using System.Xml;
@@ -45,11 +45,10 @@ namespace sones.GraphDS.Services.RemoteAPIService.ServiceContractImplementation
[ServiceBehavior(Namespace = sonesRPCServer.Namespace, IncludeExceptionDetailInFaults = true)]
public class MonoMEX : IMonoMEX
{
-
public Stream GetWSDL()
{
- var stream = Assembly.GetExecutingAssembly().GetManifestResourceStream("sones.GraphDS.Services.RemoteAPIService.ServiceContracts.MonoMEX.WSDL.xml");
+ var stream = Assembly.GetExecutingAssembly().GetManifestResourceStream("sones.GraphDS.Services.RemoteAPIService.ServiceContracts.MEX.WSDL.xml");
OutgoingWebResponseContext context = WebOperationContext.Current.OutgoingResponse;
@@ -59,7 +58,6 @@ public Stream GetWSDL()
context.ContentType = "application/xml";
context.StatusCode = System.Net.HttpStatusCode.OK;
return stream;
-
}
}
}
Oops, something went wrong.

0 comments on commit ad3a818

Please sign in to comment.