public RemotingConnectorFactory(NotificationFetcherConfig fetcherConfig) { const string channelName = "remotingConnectorClient"; _fetcherConfig = fetcherConfig; if (System.Runtime.Remoting.Channels.ChannelServices.GetChannel(channelName) == null) { IDictionary props = new Hashtable(); props["name"] = channelName; props["secure"] = "true"; props["tokenImpersonationLevel"] = "impersonation"; var sinkProvier = new System.Runtime.Remoting.Channels.BinaryClientFormatterSinkProvider(); var tcc = new System.Runtime.Remoting.Channels.Tcp.TcpClientChannel(props, sinkProvier); System.Runtime.Remoting.Channels.ChannelServices.RegisterChannel(tcc, false); } }
public RemotingConnectorFactory(NotificationFetcherConfig fetcherConfig) { const string channelName = "remotingConnectorClient"; _fetcherConfig = fetcherConfig; if (System.Runtime.Remoting.Channels.ChannelServices.GetChannel(channelName) == null) { IDictionary props = new Hashtable(); props["name"] = channelName; props["secure"] = "true"; props["tokenImpersonationLevel"] = "impersonation"; var sinkProvier = new System.Runtime.Remoting.Channels.BinaryClientFormatterSinkProvider(); var tcc = new System.Runtime.Remoting.Channels.Tcp.TcpClientChannel(props, sinkProvier); System.Runtime.Remoting.Channels.ChannelServices.RegisterChannel(tcc, false); } }
static void Main(string[] args) { var client = new System.Runtime.Remoting.Channels.Tcp.TcpClientChannel(); }