Example #1
0
        public void HandleNewProxy()
        {
            var vcall = VcallSubsystem.New();
            var config = new HostingConfiguration();

            var peer = new HostingPeer(config, vcall);

            var info = new ProxyInfo
            {
                Tag = Guid.NewGuid().ToString(),
                ListeningUri = "/tests",
                NameSpace = "Vcall.Testing",
                HostName = "localhost"
            };

            var hosting = new Hosting(peer, vcall, config);
            hosting.HandleNewProxy(info);
        }
Example #2
0
 private static IHosting new_hosting(HostingConfiguration config)
 {
     try
     {
         return
             _core.NewHosting(config);
     }
     catch (Exception ex)
     {
         throw
             Helpers.MakeNew<VcallException>(ex, _log, "Failed to create hosting");
     }
 }
Example #3
0
 /// <summary>
 /// Create custom hosting model</summary>
 /// <param name="config">Custom parameters</param>
 /// <returns>New hosting with custom parameters</returns>
 public static IHosting NewHosting(HostingConfiguration config)
 {
     assert_services_are_started();
     return
         new_hosting(config);
 }
Example #4
0
 /// <summary>
 /// Create new hosting model with default parameters ... </summary>
 /// <param name="namespace">A namespace for functions hosted by a returned hosting</param>
 /// <returns>New active hosting that is ready to host functions</returns>
 public static IHosting NewHosting(string @namespace)
 {
     assert_services_are_started();
     var config = new HostingConfiguration { NameSpace = @namespace };
     return
         new_hosting(config);
 }
Example #5
0
 /// <summary>
 /// Create new hosting model with default parameters ... </summary>
 /// <param name="visibilityScope">Hosting visibility scope (usually local host or resolving domain)</param>
 /// <returns>New active hosting that is ready to host functions</returns>
 public static IHosting NewHosting(HostingVisibilityScope visibilityScope)
 {
     assert_services_are_started();
     var config = new HostingConfiguration { VisibilityScope = visibilityScope };
     return
         new_hosting(config);
 }