您的位置:首页 > 其它

Cxf soap协议改成1.2

2015-11-27 13:21 288 查看
在和.net做联调的时候,报错:

A SOAP 1.2 message is not valid when sent to a SOAP 1.1 only endpoint.


看来是soap协议不匹配

在接口或实现类上声明

@BindingType(value = "http://www.w3.org/2003/05/soap/bindings/HTTP/")


或者

@BindingType(value = SOAPBinding.SOAP12HTTP_BINDING)


注意要引入geronimo-jaxws_2.2_spec-1.0.jar包

生成的wsdl文件我们可以看到

xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: