2012-12-17 33 views
0

我有一个WCF客户端调用Java SOAP服务(顺便提一提的是TLS和MA)。WCF SOAP操作不正确

的SOAP动作出来为:

<a:Action s:mustUnderstand="1">http://schemas.xmlsoap.org/ws/2005/02/trust/RST/Issue</a:Action> 

但我想将它设置为

<a:Action s:mustUnderstand="1">urn:example:services:201005:SendMessage</a:Action> 

我想我可以做到这一点使用下面的OperationContract特性...

[ServiceContract(Namespace = "urn:example:ns:201005", ConfigurationName = "IExampleService")] 
public interface IExampleService : IDisposable 
{ 
    [OperationContract(Action = "urn:example:services:201005:SendMessage")] 
    [FaultContract(typeof(ExampleErrorInfo), Action = "urn:example:services:201005:SendMessage", Name = "ExampleErrorInfo")] 
    [XmlSerializerFormat(SupportFaults = true)] 
    ExampleResponse SendMessage(ExampleRequest request); 
} 

为什么我的SOAP动作仍然错误?

+0

也许你在谈论一个WCF客户端.. – csg

+0

嗯,它们都是 - 但为了这个问题的目的,它是客户端。 – Fenton

+0

不应该包含服务名称空间吗? (例如urn:例如:ns:201005) – csg

回答