I have several issues with the responses sent back by Spring WS to my client. It's a J2ME JSR172 client and it seems to have a hard time parsing the response message ("Missing end tag for SOAP body or enveloper"). One of the differences between the response sent by Spring WS and the request sent by my mobile client is that there is no xml declaration in the response, something like:
Knowing that I'm using the following configuration, what should I add to include such a declaration in my response messages?Code:<?xml version="1.0" encoding="UTF-8"?>
Code:<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd"> <!-- SOAP Message Factory --> <bean id="messageFactory" class="org.springframework.ws.soap.saaj.SaajSoapMessageFactory"> <property name="messageFactory"> <bean class="com.sun.xml.messaging.saaj.soap.ver1_1.SOAPMessageFactory1_1Impl"></bean> </property> </bean> <!-- Marshalling --> <bean id="marshaller" class="org.springframework.oxm.jaxb.Jaxb2Marshaller"> <property name="contextPath" value="org.epseelon.tagspot.schemas"/> <property name="marshallerProperties"> <map> <entry key="jaxb.formatted.output"> <value type="boolean">true</value> </entry> </map> </property> </bean> <!--...--> </beans>


Reply With Quote