Made a self-hosted service in a console application. When I send a request to it, I get the error "XML parsing: line 1 character 1894 unexpected completion of input data". Exactly the same request, but smaller in size passes. 19Kb - successful, 82Kb - error. I suspect that the message is truncated to a certain length or size, but I do not understand where. I tried to increase the values ​​on the restrictions (also on the client), but without changes. Code example:

ServiceHost host = new ServiceHost(typeof(SomeService), new Uri("http://0.0.0.0:5555")); var binding = new BasicHttpBinding(); binding.MaxReceivedMessageSize = 15728640; binding.ReaderQuotas.MaxStringContentLength = 100000; binding.ReaderQuotas.MaxArrayLength = 1000; binding.ReaderQuotas.MaxDepth = 1000; binding.ReaderQuotas.MaxBytesPerRead = 15728640; binding.MaxBufferSize = 15728640; host.AddServiceEndpoint(typeof(IService), binding, "Soap"); ServiceMetadataBehavior metad = new ServiceMetadataBehavior(); metad.HttpGetEnabled = true; host.Description.Behaviors.Add(metad); host.AddServiceEndpoint(ServiceMetadataBehavior.MexContractName, MetadataExchangeBindings.CreateMexHttpBinding(), "mex"); host.Open(); 

Maybe someone knows where to dig?

    0