Beispiel #1
0
        public PipeLoggingServer()
        {
            myWeb.ILoggingService lService = new myWeb.LoggingService();
            ServiceHost           host     = new ServiceHost(lService, new[] { new Uri("net.pipe://localhost") });

            NetNamedPipeBinding b = new NetNamedPipeBinding();

            b.MaxReceivedMessageSize = 2147483647;
            b.MaxBufferPoolSize      = 2147483647;
            b.MaxBufferSize          = 2147483647;
            b.MaxConnections         = 16;

            host.AddServiceEndpoint(typeof(myWeb.ILoggingService), b, "/LoggingService");
            try
            {
                host.Open();
            }
            catch (CommunicationObjectFaultedException cofe)
            {
                throw cofe;
            }
            catch (TimeoutException te)
            {
                throw te;
            }
        }
Beispiel #2
0
        public PipeLoggingServer()
        {
            myWeb.ILoggingService lService = new myWeb.LoggingService();
            ServiceHost host = new ServiceHost(lService, new[] { new Uri("net.pipe://localhost") });

            NetNamedPipeBinding b = new NetNamedPipeBinding();

            b.MaxReceivedMessageSize = 2147483647;
            b.MaxBufferPoolSize = 2147483647;
            b.MaxBufferSize = 2147483647;
            b.MaxConnections = 16;

            host.AddServiceEndpoint(typeof(myWeb.ILoggingService), b, "/LoggingService");
            try
            {
                host.Open();
            }
            catch (CommunicationObjectFaultedException cofe)
            {
                throw cofe;
            }
            catch (TimeoutException te)
            {
                throw te;
            }
        }