Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/spring/14.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java 如何配置JaxWsPortProxyFactoryBean以使用SOAP1.2WebService_Java_Spring_Web Services_Soap - Fatal编程技术网

Java 如何配置JaxWsPortProxyFactoryBean以使用SOAP1.2WebService

Java 如何配置JaxWsPortProxyFactoryBean以使用SOAP1.2WebService,java,spring,web-services,soap,Java,Spring,Web Services,Soap,我需要使用JaxWsPortProxyFactoryBean 以下是我的Spring配置文件的片段: <bean id="documentUploadServiceJaxwsClient" class="org.springframework.remoting.jaxws.JaxWsPortProxyFactoryBean" lazy-init="true"> <property name="serviceInterface" value="org.te

我需要使用
JaxWsPortProxyFactoryBean

以下是我的Spring配置文件的片段:

<bean id="documentUploadServiceJaxwsClient"
    class="org.springframework.remoting.jaxws.JaxWsPortProxyFactoryBean"
    lazy-init="true">
    <property name="serviceInterface" value="org.tempuri.IDocumentUploadService" />
    <property name="namespaceUri" value="http://tempuri.org/" />
    <property name="serviceName" value="DocumentUploadService" />
    <property name="portName" value="secureBinding" />
    <property name="endpointAddress" ref="documentUploadServiceEndpointString" />
    <property name="customProperties" ref="internetProxyProperties"  />
    <property name="handlerResolver" ref="handlerResolver"/>
</bean>

我正在使用Spring3.0.0。我不想讨论与CXF相关的配置,因为这只是一个短期解决方案

我也尝试过使用
SOAPHandler
(脏解决方案),但服务器不允许我在运行时更改
SOAPEnvelope
。 我使用的示例代码:

SOAPMessage sm=MessageFactory.newInstance(SOAPConstants.SOAP_1_2_PROTOCOL).createMessage(mimeHeaders,newbytearrayinputstream(stream.toByteArray())

context.setMessage(sm)

Websphere给了我以下信息:

原因:java.lang.IllegalArgumentException:WSWS4117E:试图将协议为SOAP 1.1的SOAPEnvelope添加到协议为SOAP 1.2的SOAPMessage

我还尝试设置
customproperties
,但没有帮助

我需要一些相当于


但是通过使用
JaxWsPortProxyFactoryBean
理想情况下,我想让它通过简单的配置工作

我们非常感谢您在这方面提供的任何帮助


非常感谢

你运气好吗?我被困在这个问题上