I have a WCF Web service that accepts some custom objects and many documents are sent as byte arrays.
But every time I send a document (not a particularly large one), WS 400 gives a bad request, and threw a System.ServiceModel.ProtocolException: The maximum message size quota for incoming messages (65536) has been exceeded. To increase quota, use the MaxReceivedMessageSize property on the appropriate binding element. Now the customer app is in its And WCF Anyone Help will be happily received thanks nat First of all: On your server side, you define the binding configuration with the larger message size, but you do not reference it from your end point. Also: if you do the same thing on the client side Are Your Client-Side Config ( MaxReceivedMessageSizeExceeded in the trace log. Is saying
this app.config
web.config I
& lt's service behaviorConfiguration = "WCFReferrals.Service1Behavior" name = "WCFReferrals.Referrals" & gt; & Lt; Endpoint address = "" binding = "wsHttpBinding" contract = "WCFrifferrals.iffects" & gt; & Lt; Identity & gt; & Lt; Dns value = "localhost" /> & Lt; / Identification & gt; & Lt; / Endpoint & gt; & Lt; Endpoint address = "Max" binding = "wsHttpBinding" contract = "iamadadata exchanges" /> & Lt; / Services & gt; .... & lt; Binding name = "wsHttpBinding" maxBufferPoolSize = "2147483647" maximum accepted message zero = "2147483647" & gt; & Lt; Readerkots Mksdepth = "32" Mgstringkantentlength = "2147483647" Msrrylength = "2147483647" Maksbitsperread = "4096" Mksonmetablecrsunt = "16384" / & gt; & Lt; / Binding & gt; I'm obviously missing something as far as I can see that I have maximum message limitations but waaaaay is set ..
& lt; Service transaction support = "WCFReferrals.Service1Behavior" name = "WCFReferrals.Referrals" & gt; & Lt; Endpoint address = "" bond = "wsHttpBinding" bindingConfiguration = "LargeSizeMessages" & lt; == You need to specify the binding config context (as its name requires by specifying the contract = "WCFReferrals.IRFerrals"> gt; & lt; / endpoint & gt; ... .. & lt; / service & gt; ; .... & LT; binding name = "LargeSizeMessages" & lt; & lt; == it a meaningful name maxBufferPoolSize = "2147483647" maxReceivedMessageSize = "2147483647" & let gt readerQuotas maxDepth = "32" maxStringContentLength = "2147483647" maxArrayLength = "2147483647" maxBytesPerRead = "4096" maxNameTableCharCount = "16384" / & gt; & lt; / binding & gt;
a Pp.config or
web.config ) contains the binding configuration of that large message size? Do you referenced your
& lt; customer & Gt; .. & lt; end point & gt; element
Comments
Post a Comment