c# - Deploying service to remote web server throws exception: 'There was an error deserializing the object of type XXXX' -


i've seen few questions answered on subject none seem match scenario.

i have local asp.net mvc app that's connecting local development instance of wfc service. if send large string param local development service, fine. when deploy exact same service remote web server, following error (where xxxx namespaced object in service):

"the formatter threw exception while trying deserialize message: there error while trying deserialize parameter http://tempuri.org/:formpost. innerexception message 'there error deserializing object of type xxxx. maximum string content length quota (8192) has been exceeded while reading xml data. quota may increased changing maxstringcontentlength property on xmldictionaryreaderquotas object used when creating xml reader. line 1, position 10304."

here's odd thing:

  1. the codebase on local service (on localhost) , on remote service (at www.myurl.com) same. yet when switch client app (running on localhost) between them error on remote service, not local.

  2. when change maxstringcontentlength property value 2147483647 on local client, makes no difference. , endpoint using correct binding name.

    <binding name="basichttpbinding_itheservice" closetimeout="00:01:00"       opentimeout="01:10:00" receivetimeout="01:10:00" sendtimeout="01:10:00"       allowcookies="false" bypassproxyonlocal="false" hostnamecomparisonmode="strongwildcard"       maxbufferpoolsize="2147483647" maxbuffersize="2147483647" maxreceivedmessagesize="2147483647"       textencoding="utf-8" transfermode="buffered" usedefaultwebproxy="true">       <readerquotas maxdepth="32" **maxstringcontentlength="8192"** maxarraylength="16384"         maxbytesperread="4096" maxnametablecharcount="16384" />       <security mode="none">         <transport clientcredentialtype="none" proxycredentialtype="none"           realm="" />         <message clientcredentialtype="username" algorithmsuite="default" />       </security>     </binding>  <binding name="basichttpbinding_itheservice" closetimeout="00:01:00"       opentimeout="01:10:00" receivetimeout="01:10:00" sendtimeout="01:10:00"       allowcookies="false" bypassproxyonlocal="false" hostnamecomparisonmode="strongwildcard"       maxbufferpoolsize="2147483647" maxbuffersize="2147483647" maxreceivedmessagesize="2147483647"       textencoding="utf-8" transfermode="buffered" usedefaultwebproxy="true">       <readerquotas maxdepth="32" **maxstringcontentlength="2147483647"** maxarraylength="16384"         maxbytesperread="4096" maxnametablecharcount="16384" />       <security mode="none">         <transport clientcredentialtype="none" proxycredentialtype="none"           realm="" />         <message clientcredentialtype="username" algorithmsuite="default" />       </security>     </binding> 
  3. there no binding configuration in service-side web.config file change. on client. yet error referring failure deserialize object service-side class.


Comments

Popular posts from this blog

PHP DOM loadHTML() method unusual warning -

python - How to create jsonb index using GIN on SQLAlchemy? -

c# - TransactionScope not rolling back although no complete() is called -