For my customer I have to marshal a XML file (received from an external service) to Java entities, and save it on database. For that I am using a simple Jaxb method that does the job.
I have an issue with the XML file. I received it and I don't understand why acute accent caracter doesn't show correctly in the file. It is encoded in UTF-8 in Unix (LF). Acute accent is display like that in the file :
When copy it and paste it on a new file it is correctly displayed.
The problem is that when Jaxb process the file, I get this error:
org.springframework.dao.DataAccessResourceFailureException: Error reading XML stream; nested exception is javax.xml.stream.XMLStreamException: ParseError at [row,col]:[14642,669]
Message: The element type "Nm" must be terminated by the matching end-tag "</Nm>".
It's not an end-tag issue, it is correctly closed. Wen I replace this "XB4" caracter by another one, it works properly.
Java file encoding format is UTF-8.
Does someone have an idea ?
Thanks a lot.