I have a web service call that Adeptia appears to be HTML-Encoding the results from. Specifically, once the result is received I send it's result to a text file target and find that many of the characters are translated, such as > where > was sent.
What encoding or other option should be used to change these back to original characters?
You can encode the data as base64 at server side(in mapper where it is creating response) and at client side you can decode the data back to the original form. Please compile the attached "EncodingUtility.java" file and create a custom class, that you can use to encode and decode data in Data Mapper. To use this utility follow below steps:
• Place the compiled EncodingUtility.class into custom class folder.
• Restart the Adeptia Suite.
• Open data Mapping which is creating response.
• Now you can find the EncodingUtility methods into "Global Methods" in Data mapper.
• Encode the mapping by using encodeStringAsBase64(dataToEncode) method.
• At client side use decodeStringAsBase64(dataToDecode) method.
So the Web Service Client should decode base 64 at your end. We have attached the "decode" method that you can refer to for decoding. Please let us know if you have any issues.
The changes that you have to perform in Data mapping should be like “java:EncodingUtility.encodeStringAsBase64($Input_inputSchema/Root/Record/StreamData)”.