I need to pass more than 64kb of data through the WCF service. To do that I've configured server side (that hosts WCF service) in the following way:
<services>
<service name="MyService" behaviorConfiguration="MyServiceBehavior" >
<endpoint address="" binding="customBinding" contract="MyContract"
bindingName="testBinding" bindingConfiguration="testBinding" />
<endpoint address="mex" binding="customBinding" contract="IMetadataExchange"
bindingName="testBinding" bindingConfiguration="testBinding" />
</service>
</services>
<bindings>
<customBinding>
<binding name="testBinding" >
<textMessageEncoding>
<readerQuotas maxDepth="2147483647"
maxStringContentLength="2147483647"
maxArrayLength="2147483647"
maxBytesPerRead="2147483647"
maxNameTableCharCount="2147483647" />
</textMessageEncoding>
<httpTransport transferMode="Buffered"
maxReceivedMessageSize="2147483647"
maxBufferSize="2147483647"/>
</binding>
</customBinding>
</bindings>
And client side (that consumes service):
<client>
<endpoint address="http://localhost:82/MyService.svc"
binding="customBinding" bindingConfiguration="testBinding"
contract="MyContract"
name="MyName" />
</client>
<bindings>
<customBinding>
<binding name="testBinding" >
<textMessageEncoding>
<readerQuotas maxDepth="2147483647"
maxStringContentLength="2147483647"
maxArrayLength="2147483647"
maxBytesPerRead="2147483647"
maxNameTableCharCount="2147483647" />
</textMessageEncoding>
<httpTransport transferMode="Buffered"
maxReceivedMessageSize="2147483647"
maxBufferSize="2147483647"/>
</binding>
</customBinding>
</bindings>
When I called required method I've received the following error:
Content Type application/soap+xml; charset=utf-8 was not supported by service http://localhost:82/MyService.svc. The client and service bindings may be mismatched.
Please advice, what is mismatch in my bindings?
Thanks.