Hi David
On 07/10/13 10:54, David Karlsen wrote:
Hi.
I have an existing jax-ws service that I now additionally want to expose as
a REST/jax-rs service.
I've configured it like this: *http://pastebin.com/h7cy8ZYB *
The wadl generated looks like: *http://pastebin.com/QQRbNb3n *
I would expect it to refer to the request /response types not to look like
<representation mediaType="application/xml"/>
but rather something like:
<representation mediaType="application/xml"
type="tns:customerCreateRequest" />
I've tried adding @XmlName etc but nothing changes.
I suspect the reason you don't have the proper mappings generated is
that the JAX-WS generated code has the bean parameters with JAXB XMLType
only and the JAX-RS runtime does wrap/unwrap the types.
How do you use XMLName ? It needs to contain extended QNames, example
"{http://myns}MyRootElement".
As a side note, the configuration can be simplified:
- two conflicting JAXB providers, need to drop either jaxrs:dataBinding
or JAXBProvider,
- two Jackson providers, I'm not sure which one will work better in your
case, please try
- re the schema validation, you need to get that schema list set up only
once, using SchemaHandler makes sense only if you reuse it between CXF
JAXB and JSON providers, but you don't, so drop it; next , if you decide
to keep JAXBProvider then drop jaxrs:schemaLocations
Cheers, Sergey
Any hints?
--
David J. M. Karlsen - http://www.linkedin.com/in/davidkarlsen