gpt4 book ai didi

wcf - WCF 可靠 session 的问题(可靠消息传递)

转载 作者:行者123 更新时间:2023-12-04 00:48:47 26 4
gpt4 key购买 nike

在我们的 WCF 应用程序中,我正在尝试配置可靠的 session 。

服务:

 <wsHttpBinding>
<binding name="BindingStabiHTTP" maxBufferPoolSize="524288"
maxReceivedMessageSize="2097152"
messageEncoding="Text">
<reliableSession enabled="true" ordered="true"
inactivityTimeout="00:10:00"/>
<readerQuotas maxDepth="0" maxStringContentLength="0"
maxArrayLength="0" maxBytesPerRead="0"
maxNameTableCharCount="0" />
</binding>
</wsHttpBinding>

客户:
 <wsHttpBinding>
<binding name="BindingClientWsHttpStandard" closeTimeout="00:01:00"
openTimeout="00:01:00" receiveTimeout="00:10:00"
sendTimeout="00:01:00" bypassProxyOnLocal="false"
transactionFlow="false" hostNameComparisonMode="StrongWildcard"
maxBufferPoolSize="524288" maxReceivedMessageSize="65536"
messageEncoding="Text" textEncoding="utf-8"
useDefaultWebProxy="true" allowCookies="false">
<readerQuotas maxDepth="32" maxStringContentLength="8192"
maxArrayLength="16384" maxBytesPerRead="4096"
maxNameTableCharCount="16384" />
<reliableSession ordered="true" inactivityTimeout="00:10:00"
enabled="true" />
<security mode="Message">
<transport clientCredentialType="Windows" proxyCredentialType="None"
realm="" />
<message clientCredentialType="Windows"
negotiateServiceCredential="true"
algorithmSuite="Default" establishSecurityContext="true" />
</security>
</binding>

不幸的是,我收到如下错误:
没有为带有“ http://schemas.xmlsoap.org/ws/2005/02/rm/CreateSequence”的消息指定签名消息部分' 行动。

如果我在客户端上禁用了可靠 session ,我会收到以下消息:
此端点不支持该操作。此端点仅处理 WS-ReliableMessaging 2005 年 2 月的消息。

因此,似乎为 RM 正确配置了服务器。

我找不到任何有值(value)的错误信息,所以我不知道如何解决这个问题。有什么想法可能是错的吗?

预先感谢,

最佳答案

在开始一个与 RM 配合良好的新测试项目后,我终于通过比较配置文件发现了问题。看来我们的服务配置没有指定正确的绑定(bind)配置:

<service behaviorConfiguration="somebehavior"
name="somename">
<endpoint address="" binding="wsHttpBinding"
bindingConfiguration="SomeBinding"
name="http"
contract="somecontract" />
<endpoint address="mex"
binding="mexHttpBinding"
bindingConfiguration=""
name="mex"
contract="IMetadataExchange" />
<host>
<baseAddresses>
<add baseAddress="http://localhost:8731/Design_Time_Addresses/somelibrary/someservice/" />
</baseAddresses>
</host>
</service>

此 bindingConfiguration 为空。然后它采用默认的 wsHttpBinding,它与指定的不同(即使只有 1 个)。

关于wcf - WCF 可靠 session 的问题(可靠消息传递),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2913596/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com