I've created, using the built-in project template, a WCF REST-based service. Everything works just great except that when I attempt to "POST" a file (as a stream) to one of my operations, I'm consistently getting a 413 (Entity Too Large) response.
I've looked at all the other 413 questions related to WCF and they're all related to non-REST services and/or IIS6 configurations and mention either the <system.Web>
or <binding>
properties.
Any ideas?
Well... I figured it out!
It turns out that the setting which worked is one which has to be applied to the standardEndpoint node inside system.serviceModel node:
<system.serviceModel>
<standardEndpoints>
<webHttpEndpoint>
<standardEndpoint name=""
helpEnabled="true"
automaticFormatSelectionEnabled="true"
maxReceivedMessageSize="2147000000"
/>
</webHttpEndpoint>
</standardEndpoints>
</system.serviceModel>
Check the quotas and max's in your config file maxmessagesize, etc. defaults are 8192, 16384, 65536
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With