Any clues, anyone? I've been struggling with this for too long now, read all
possible and impossible forum posts, bug reports, etc. (the positive side of
this is that I have a much better understanding of web services now) ;)

I've also tried to use Aegis instead of JAXB (with both JAX-WS and the
Simple frontend), and set the writeXsiTypes and readXsiTypes properties of
the aegis context to "true" but I still don't get the xsi:type on the
returned value.

I think the question here is if my expectation is correct: should I have the
xsi:type with my current configuration in the <return> element or not? If
not, can I somehow get it there?

Thanks,
Rado




immutability wrote:
> 
> Hello everyone - I'm new to webservices in Java, so my issue may be some
> trivial, but I've had a hard time trying to figure this out. I've been
> playing with CXF for a while, and I've created a simple web service to
> test integration with spring.
> 
> It all seems to be working fine, but what I need to do is make this
> compatible with older versions of client applications which are using
> org.apache.soap to talk to the service. Currently, these applications can
> properly call methods of my webservice, but fail to parse the returned
> response, possibly due to the missing xsi:type attribute. My testing
> service is currently very simple and contains a single method "login"
> accepting 2 string parameters username and password:
> 
> @WebService
> public interface HelloService
> {
>       boolean login(
>                       @WebParam(name = "username") 
>                       String username, 
>                       @WebParam(name = "password")
>                       String password);
> }
> 
> The JAX-WS endpoint is defined in my spring XML.
> 
> The SOAP response looks like this:
> 
> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/";>
>       <soap:Body>
>               <ns1:loginResponse xmlns:ns1="urn:soap-interface">
>                       <return>true</return>
>               </ns1:loginResponse>
>       </soap:Body>
> </soap:Envelope>
> 
> It looks like the clients expect the following:
> <return xsi:type="xsd:boolean">false</return>
> 
> Is there a way for me to make CXF add the xsi:type attribute to the return
> value somehow? Am I doing something wrong here, or do I need to use some
> annotation to make it use the xsi:type?
> 
> Again, I apologize if this is something stupid, I'm still learning. Thanks
> for any clues in advance!
> 
> Rado
> 

-- 
View this message in context: 
http://www.nabble.com/xsi%3Atype-missing-in-returned-value-tp22410060p22501441.html
Sent from the cxf-user mailing list archive at Nabble.com.

Reply via email to