【问题标题】:The message with Action '' cannot be processed at the receiver,接收方无法处理带有 Action '' 的消息,
【发布时间】:2013-09-22 13:07:33
【问题描述】:

我有客户端提供的 WSDl,我需要根据它创建 WCF 服务

它在我尝试使用以下配置在 WCF 中实现的 soap 1.2 下没有提供任何肥皂动作

当我尝试使用soap UI提交和应用程序时,我收到以下错误

<s:Envelope xmlns:s="http://www.w3.org/2003/05/soap-envelope">
   <s:Body>
      <s:Fault>
         <s:Code>
            <s:Value>s:Sender</s:Value>
            <s:Subcode>
               <s:Value xmlns:a="http://schemas.microsoft.com/ws/2005/05/addressing/none">a:ActionNotSupported</s:Value>
            </s:Subcode>
         </s:Code>
         <s:Reason>
            <s:Text xml:lang="en-US">The message with Action '' cannot be processed at the receiver, due to a ContractFilter mismatch at the EndpointDispatcher. This may be because of either a contract mismatch (mismatched Actions between sender and receiver) or a binding/security mismatch between the sender and the receiver.  Check that sender and receiver have the same contract and the same binding (including security requirements, e.g. Message, Transport, None).</s:Text>
         </s:Reason>
         <s:Detail>
            <z:anyType i:nil="true" xmlns:z="http://schemas.microsoft.com/2003/10/Serialization/" xmlns:i="http://www.w3.org/2001/XMLSchema-instance"/>
         </s:Detail>
      </s:Fault>
   </s:Body>
</s:Envelope>

<services>
  <service name="Myservice" behaviorConfiguration="MyServiceTypeBehaviors">
    <endpoint name="MyserviceEndpoint" address="soap12" 
              binding="customBinding" bindingNamespace="http://Myservice.namespace"
              bindingConfiguration="httpSoap12" contract="IMyService"/>

  </service>
</services>
<behaviors>
  <serviceBehaviors>
    <behavior name="MyServiceTypeBehaviors" >
      <serviceMetadata httpGetEnabled="true" />
    </behavior>
  </serviceBehaviors>
</behaviors>
<serviceHostingEnvironment multipleSiteBindingsEnabled="true" />

【问题讨论】:

    标签: c# wcf c#-4.0 soap wcf-binding


    【解决方案1】:

    various interpretations如果没有指定soapAction怎么办(例如可能有默认soapaction)。我建议设置 wcf 客户端和服务器,看看客户端发送了什么soapAction。这是所有客户端都应该发送的soapAction。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2016-09-25
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-03-06
      相关资源
      最近更新 更多