从 Biztalk 使用 WCF Web 服务时出现最大字符串内容长度配额错误

发布于 2024-08-29 03:19:42 字数 478 浏览 3 评论 0原文

我收到此错误消息......

"The Maximum string content length quota (8192) has been exceeded while reading 
XML data. This quota may be increased by changing the MaxStringContentLength 
property on the XmlDictionaryReaderQuotas object used when creating the XML 
reader"

在我使用 WCF Web 服务的编排之一中(堆栈跟踪表明接收形状是问题所在)。很可能反应会非常大。

查看带有此错误消息的其他一些问题,解决方案是更改配置文件中的 WCF 绑定设置。但是,当我使用 BizTalk 时,我找不到这些配置设置。它们似乎没有在任何地方生成,我应该尝试将它们添加到 BTSNTSVc.exe.config 吗?

欢迎任何建议。

I'm getting this error message ...

"The Maximum string content length quota (8192) has been exceeded while reading 
XML data. This quota may be increased by changing the MaxStringContentLength 
property on the XmlDictionaryReaderQuotas object used when creating the XML 
reader"

... in the one of my orchestrations that consumes a WCF webservice (stacktrace indicates the receive shape is where the issue is). It is likely that the response is very large.

Looking at some of the other questions with this error message, the solution is to change a WCF bindings setting in the configuration file. However I can't find these configuration settings when I'm using BizTalk. They don't seem to be generated anywhere, should I be trying to add them to BTSNTSVc.exe.config ?

Any suggestions welcome.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

绝對不後悔。 2024-09-05 03:19:42

您可以控制服务器端代码吗?如果是这样,请更改那里的配置并重新生成服务引用。应类似于 ma​​xStringContentLength="2147483647"

<bindings>
  <wsHttpBinding>
    <binding name="newHTTPBinding" 
             maxBufferPoolSize="2147483647"  
             maxReceivedMessageSize="2147483647">
      <readerQuotas maxDepth="32" 
                    maxStringContentLength="2147483647"
                    maxArrayLength="16384" 
                    maxBytesPerRead="4096" 
                    maxNameTableCharCount="16384" />
    <binding/>
  <wsHttpBinding>
<bindings>

Do you have control over the server side code? If so, change the config there and regenerate the service reference. Should look something like maxStringContentLength="2147483647":

<bindings>
  <wsHttpBinding>
    <binding name="newHTTPBinding" 
             maxBufferPoolSize="2147483647"  
             maxReceivedMessageSize="2147483647">
      <readerQuotas maxDepth="32" 
                    maxStringContentLength="2147483647"
                    maxArrayLength="16384" 
                    maxBytesPerRead="4096" 
                    maxNameTableCharCount="16384" />
    <binding/>
  <wsHttpBinding>
<bindings>
小嗲 2024-09-05 03:19:42

我通过在 basicHTTPBinding 下添加默认绑定解决了该问题,就像 http://social.msdn.microsoft.com/Forums/en-US/wcf/thread/d5b7ac03-70f8-4366-b055-c177c61f4dec/

必要的修改是完成给客户。

I have fixed the problem by adding a default binding under basicHTTPBinding, just like in http://social.msdn.microsoft.com/Forums/en-US/wcf/thread/d5b7ac03-70f8-4366-b055-c177c61f4dec/

The necessary modification was done to the client.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文