Hi All,
We have Email (using Mail Package XSD) to File Scenario. PI reads Email from Microsoft Exchange Server and writes the HTML content from Content Tag into File Dir which is further processed by Receiving system.
We are able to handle Content Type data for Content-Type: text/html , Content-Type: text/plain, Content-Type: Base64 without any issue.
However we notice (In PI Input Payload from Moni) for few of the Emails that come into PI, there is additional Encoding as : Content-Transfer-Encoding: quoted-printable. Once PI writes the data into HTML for these Emails, the HTML file does not display the data correctly rather there are some unwanted =, =3D, <p/> values appearing in the HTML file which makes it unreadable (sample Screenshot attached)
We tried to use the standard Java APIs in PI UDF to Decode this "quoted-printable" format, but its not solving our issue completely. We still get =, <= /p> (these are Soft Line Breaks that are added as part of quoted-printable encoding) in the HTML file. If we need to remove these unwanted chars from Content, then we would need to read the data Line by Line in PI and apply our logic in UDF- but with this approach there is risk of PI performance.
Please suggest steps / java Code/API to handle & decode : quoted-printable to readable format. And also suggest how much it will impact PI performances (there are about 50+ mails daily in this quoted-printable format).
(The receiving system is not capable to Decode the File and expects PI to place HTML files in readable / exact format as Sent by Sender).
Regards,
Azhar