JAXBContext jaxbContext = JAXBContextHelper.createJAXBContext(context, false);
try {
unmarshaller = JAXBContextHelper.getUnmarshaller(jaxbContext);
reader = source.getXMLStreamReaderWithoutCaching();
// https://issues.apache.org/jira/browse/WSCOMMONS-395
reader = new StreamReaderDelegate(reader) {
// Fix the issue in WSCOMMONS-395
public String getAttributeType(int index) {
String type = super.getAttributeType(index);
return type == null ? "CDATA" : type;
}