Jeremy Robertson
2011-03-28 18:57:46 UTC
Is there a way to configure a CXF service to ignore the javax.xml.bind.UnmarshalException "unexpected element"?
The desired functionality is that when the unmarshaller hits an element that it does not understand, it ignores it and moves on, rather than throwing the above exception.
We generate both services and clients, and in previous versions of CXF (I think pre 2.3), elements that were not understood were ignored. This allowed us to extend data objects in the service without having to rebuild clients in legacy systems. Having upgraded a project to 2.3.1, I am now getting the unexpected element error (I'm not entirely sure what other dependencies were also upgraded, so it may be separate from CXF, in which case, sorry to bother).
Is there a property I can set on the JAXBDataBinding class that will affect this? Is there somewhere online I should be looking (I've tried, but haven't found much yet)?
Thanks for your time,
Jeremy
NOTICE: This email message is for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply email and destroy all copies of the original message.
The desired functionality is that when the unmarshaller hits an element that it does not understand, it ignores it and moves on, rather than throwing the above exception.
We generate both services and clients, and in previous versions of CXF (I think pre 2.3), elements that were not understood were ignored. This allowed us to extend data objects in the service without having to rebuild clients in legacy systems. Having upgraded a project to 2.3.1, I am now getting the unexpected element error (I'm not entirely sure what other dependencies were also upgraded, so it may be separate from CXF, in which case, sorry to bother).
Is there a property I can set on the JAXBDataBinding class that will affect this? Is there somewhere online I should be looking (I've tried, but haven't found much yet)?
Thanks for your time,
Jeremy
NOTICE: This email message is for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply email and destroy all copies of the original message.