access BTS 2004 via HTTP or SOAP?

Home Page Forums BizTalk 2004 – BizTalk 2010 access BTS 2004 via HTTP or SOAP?

Viewing 1 reply thread
  • Author
    Posts
    • #13425

      Hi there,

      I’d like to do some application integration using BTS 2004. My scenario is rather simple, I’ve three components:
      1. My application (MyApp)
      2. An external application (ExtApp)
      3. BTS 2004 as bridge between MyApp and ExtApp.

      Now there are two things to get accomplished:
      -transferring data from MyApp to ExtApp
      -transferring data from ExtApp to MyApp

      What I’ve done so far is to use FILE as transfer protocol. Data generated by MyApp is written to a ReceiveLocation of a ReceivePort, and the corresponding SendPort applies a Mapping to the Message and writes the result to the directory specified by the SendPort. Messages from ExtApp are expected to be written as files to another ReceivePort’s ReceiveLocation; MyApp then polls the associated SendPorts directory for messages.

      While this approach works, communication using file transfer over common directories of course is not state of the art and has some major drawbacks, considering problems arising from missing file system permissions, the necessity for MyApp to poll the directory for messages coming from ExtApp etc.

      Therefore I’d like to know, if (and maybe how) it’s possible to implement the described szenario using a more reliable way. How can I transfer data to BTS and from BTS using HTTP (MyApp is implemented in Python)?

      Since I’m new to web services and SOAP, can anybody give me some information on acessing BTS via HTTP in the above manner?

      Thanx in advance

      Slash

    • #13426

      I would recommend web services, more state of the art and probably easier to implement than HTTP.

      1. Use the Biztalk Web Service Publishing wizard to publish your orchestration as a web service. You will need to set the Type Modifier on the orchestration Receive Port to Public.
      This will create and build a VS Web Service project. Open IIS Admin and add an Application Pool for this virtual directory. Set the App Pool idenity to your BiztalkIsolated account.

      2. I assume you are using VS.NET to build your app. Open up your MyApp project and Add a web reference. You need to specify the URL of the web service e.g. http://biztalkserver/Service/Service.asmx. VS will create the class files you require – a class for the service and classes that make up the message. Make an instance of the message class, populate the fields, create an instance of the service class and call the required method passing your message. You don’t have to touch any Xml in the whole process. All the serialization code is created for you.

      This is fairly high level. You could try one of the Web Service turtorials that will step you through publishing a web service from Biztalk.

      While there is nothing wrong with the HTTP interface, in fact it is slightly easier to set up on Biztalk, it requires a lot more code within your application, including handcrafting the Xml either by using XmlDocument or creating your own classes and using XmlSerialization.

      • #13427

        Oops, missed that in the original post.
        Still plenty of resources available for implementing Web Services in Python

        [url]http://pywebsvcs.sourceforge.net/[/url]

        [url]http://diveintopython.org/soap_web_services/[/url]

        [url]http://aspn.activestate.com/ASPN/WebServices/SWSAPI/pytut[/url]

        • #13428

          Just like you created a Receive Port and added a flat-file Receive Location, you can add a second Receive Location which would have a transport-protocol of HTTP.

          The Biztalk documentation gives a nice [b:7acc4ae94e]long [/b:7acc4ae94e]checklist of how to properly setup the HTTP receive location (one set for IIS5 and another set for IIS6). You have to set up IIS and even COM+ and application pools to get it to work (you will need Admin rights). It works great, but at least for me, it rarely works properly the first time, usually some security settings somewhere are wrong. So while getting a flat file receive may take 10 minutes, you’d better plan for one to four hours to get the http receive working the first time you try it.

          My suggestion is that you create a script to test your http post and be sure and check the http status code.

          Shameless Plug: I have a video that walks through the entire process on the Biztalk CD/ROMs that I sell at the website below.

          Neal Walters
          http://Biztalk-Training.com

Viewing 1 reply thread
  • The forum ‘BizTalk 2004 – BizTalk 2010’ is closed to new topics and replies.