I interpreted your response on "did you write your own serializer" as client side activity to serialize
java to xml
On the server side I use Apache CXF framework web services. I did not write any specific serializer.
I am not understanding where can I intersperse the check and fix to make the xml payload well-formed received as part of the request