BizTalk SMTP 消息部分获取 XML 编码

发布于 2024-08-31 20:53:30 字数 931 浏览 1 评论 0原文

我有一封电子邮件多部分消息,用于将失败的消息路由从消息框发送到业务用户邮箱。

Email{ Body - RawString; OriginalMessage - string};

原始消息是从接收到的激活编排的消息中设置的。例如,假设原始失败消息来自未能反汇编内容的平面文件:

Order,1,2,3,4,5,<6>,

我使用以下方法设置消息:

Email.OriginalMessage = MyUtil.XlangMsgToStringMethod(FailedMessage);// XmlDocument type, this can be malformed xml, valid xml, or flat file that fails in disassembler.

然后我可以写入事件日志以测试 Email.OriginalMessage 中的内容:

System.Diagnostics.EventLog.WriteEntry(" BizTalk Server 2006”,电子邮件.原始消息,信息); // 这将显示正确的原始消息“Order, 1,2,3,4,5,<6>,”

当使用 SMTP 服务器和动态发送端口传递电子邮件且附件设置为text/plain mime 类型,原始消息经过 xml 编码转义并封装在 xml 中:

<?xml version="1.0"?>
<string>Order, 1,2,3,4,5,&lt;6&gt;,</string>

有什么想法吗? SMTP 端口具有 passthrutransmit 作为管道。

谢谢。

I have a email multi-part message which I am using to send failed message routing from the messagebox to a business users mailbox.

Email{ Body - RawString; OriginalMessage - string};

The original message gets set from the received message that activates the orchestration. For example assume the original failed message is from a Flat file that failed disassembly with the contents:

Order,1,2,3,4,5,<6>,

I set the message using:

Email.OriginalMessage = MyUtil.XlangMsgToStringMethod(FailedMessage);// XmlDocument type, this can be malformed xml, valid xml, or flat file that fails in disassembler.

I can then write to the event log to test whats in Email.OriginalMessage:

System.Diagnostics.EventLog.WriteEntry("BizTalk Server 2006", Email.OriginalMessage, Information); // This displays the correct original message "Order, 1,2,3,4,5,<6>,"

When the email is delivered using a SMTP server and a dynamic send port, with the attachment set to text/plain mime type, the original message gets xml encoding escaped and wrapped in xml:

<?xml version="1.0"?>
<string>Order, 1,2,3,4,5,<6>,</string>

Any ideas why? The SMTP port has passthrutransmit as pipeline.

Thanks.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

心是晴朗的。 2024-09-07 20:53:30

SMTP 端口正在获取 XMLTransmit,强制将消息视为 XML。
切换到直通传输。

SMTP port is getting XMLTransmit forcing the message to be treated as XML.
Switch to PassThroughTransmit.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文