Ok.  I changed my operation to wrap my type in a JAXBElement as in....

@POST
public Response addAccount( @Context HttpHeaders requestHeaders,
JAXBElement<AccountType> jaxbElement )


and this works.  However when making this change to my other operations i
have hit an issue.  One of my operations takes in a superclass and then i
cast it to one of three types under the covers as in:


@POST
@Path("/{id}/localIds")
public Response addLocalId( @Context HttpHeaders requestHeaders,
@PathParam("id") Integer id, JAXBElement<IdentifierType> jaxbElement )

where IdentiferType is the Superclass of three different types.  This worked
before i had to wrap everything in JAXBElement objects.


This is a _showstopper_ for me and any help would be greatly appreciated....



On Wed, Aug 12, 2009 at 10:59 AM, Nathaniel Auvil <[email protected]
> wrote:

> org.apache.cxf.interceptor.Fault: argument type mismatch while invoking
> public javax.ws.rs.core.Response
> com.xxx.ws.AccountsService.addAccount&#40;javax.ws.rs.core.HttpHeaders,com.xxx.ws.types.AccountType&#41;
> with params [org.apache.cxf.jaxrs.impl.httpheadersi...@1a242fc,
> javax.xml.bind.jaxbelem...@1a2bf9b]
>
> I have not seen this error before and i did not change my JAXB generated
> types since the other day when i compiled.  I have my maven properties set
> to 2.2.2
>
> Any ideas?
>
>
>
>

Reply via email to