Dan, thank you for your quick reply.

You nailed down the problem really well,  I was indeed using jax-ws services
(well, REST but using http bindings) and I should have used the @WebResult
annotation directly on the SEI instead of annotating the types.

I fixed it and it works perfectly now. My SEI looks more or less like this:

    @Get
    @HttpResource(location = "/workorder/{id}")
    @WebResult(name="getRequestInformationResponse")
    public GetRequestInformationResponse getWorkOrder(@WebParam(name = "id")
String id){ ...}

and on the types I only kept the @XmlAccessorType(XmlAccessType.FIELD)
annotation.
Strangely enough, it was working with XmlRootElement in < 2.0.3 CXF
verisons.

Thanks again
Rui Ramos


dkulp wrote:
> 
> 
> I'd probably need to see the method signature on the SEI and the  
> annotations there.  Also, are you talking JAX-WS SEI interface or REST  
> or what?  Per jax-ws/jws spec, the name of the element used for the  
> request/response  is taken from the WebResult/WebParam annotations,  
> NOT the XmlRootElement annotation on the types.   This is per spec for  
> those cases.
> 
> Dan
> 
> 
-- 
View this message in context: 
http://www.nabble.com/%40XmlRootElement-name-not-working-in-2.0.6--tp17316700p17340396.html
Sent from the cxf-user mailing list archive at Nabble.com.

Reply via email to