The short answer to your question is, yes, just use string fields.
To dive in a little deeper, whether or not to just use string fields depends on how you want your document types and integrations to behave.
If you don’t need strongly-typed fields in your documents (and you probably don’t) then you don’t need to do anything further. Just use string fields. One exception may the date/timestamp fields. You may want/need to convert those to a common/known format. The W3C timestamp format is a good one to convert to if: a) the XML doc you’re processing doesn’t already use that format; b) you don’t already have another standard format that your enterprise uses.
If you want strongly-typed fields in your documents (I would strongly advise against doing this, except perhaps for Date fields), then you’ll need to do a bit more work. The content-type specified in the XML for each field is advice for how to convert the string to the desired type.
Define the IS doc type as you described, using object fields with a Java wrapper type. Then when processing the incoming XML document, you’ll need to convert each field from a string to the appropriate object type. Convert the date string to a java.util.Date, convert the integer string to a java.lang.Integer, etc.
You might want to drop the use of the word “canonical” when referring to your publishable document type. Chances are, it’s not a canonical document type in any sense of the word.
Hope this helps.
#Flow-and-Java-services#webMethods#Integration-Server-and-ESB