开发者

BizTalk Send Flat File to Web Service

I currently have a BizTalk 2006 (r1) application which receives XML from a SQL stored proc using the SQL adapter. It maps this to another schema before sending out to a 3rd party. The send port uses a custom pipeline component which converts the XML to a flat file - in the format required by the customer. I don't use any orchestration, this is a pure m开发者_如何学Goessage based solution.

This all works great when sending via FTP. However, the 3rd party have now requested that I push the message to a web service they hosy. I haven't received the WSDL yet but can assume that the method I'll be calling simply receives a string as a single parameter.

Could anyone advise on the best way to approach this please? I have created a simple web service stub. I then followed Recipe 6-11 from the excellent BizTalk 2006 Recipes book, generating a proxy class using wsdl.exe which I then reference from the "web service" tab of the SOAP send port. However, when processing an order I get the following message in the event log:

Could not load type 'WSProxy' from assembly 'Direct.IS.Payment.Components, Version=3.1.145.0, Culture=neutral, PublicKeyToken=dc03da781bea1472'.". The type must derive from System.Web.Services.Protocols.SoapHttpClientProtocol. The type must have the attribute System.Web.Services.WebServiceBindingAttribute. ".

Next step will be for me to play around with the proxy so that it address the derive and attribute issues mentioned in the even log message. However, I can't help but think that there must be an easier way?

Thanks


The custom pipeline component you have created is not producing a message that is suitable for SOAP transmission. Not knowing what the end customer is going to do, I'd hold off on trying ot make SOAP work. In the mean time, just spin up an ASPX page with the following code:

  private void Page_Load(object sender, EventArgs e)
  {
    StreamReader reader = new StreamReader(page.Request.InputStream);
    String xmlData = reader.ReadToEnd(); 
  }

Add code to write XMLData to a DB or to a text file or something to see what it is. This is very crude and does not send a response code. It should get you started.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜