Bridging between TIBCO Messaging Transport and BizTalk


TIBCO Adapter for COM can be used as a bridge between the TIBCO messaging infrastructure and Microsoft's BizTalk Server. TIBCO messages can flow from the TIBCO messaging transport to BizTalk, and BizTalk messages can flow from BizTalk to the TIBCO messaging transport.

This example is developed to work with Microsoft BizTalk Server 2000 and Microsoft Windows 2000. If you want to run this example using Microsoft BizTalk Server 2004, you will have to write a custom component that will help Microsoft BizTalk Server 2004 interface with the adapter.

To illustrate this functionality, this section provides a simple example of a BizTalk schedule that receives messages from the TIBCO messaging transport and republishes them to the TIBCO messaging transport on a different subject.

To keep it simple, the interface/message format for both incoming and outgoing messages are the same, although they can be different.

In this example, you will create a TIBCO Adapter for COM interface that defines the format of messages and then set configuration parameters in BizTalk Orchestration Designer and TIBCO Designer.

The tasks are:

Define the COM interface

  1. Use MSVC++ or VB to create a COM coclass named Comp with an interface, IComp, that satisfies the following IDL:
  2.    < 
          uuid(44EC00B5-5786-40AB-A26F-6ACAE1EC09B7), 
          version(1.0), 
          helpstring("QComp 1.0 Type Library") 
       > 
       library QCOMPLib 
       { 
             importlib("stdole2.tlb"); 
     
             interface IComp; 
     
             < 
             uuid(90C89293-9CE6-44BA-AC1D-8977FB6C4618), 
             helpstring("Comp Class") 
             > 
             coclass Comp { 
             <default> interface IComp; 
       }; 
     
       < 
       odl, 
       uuid(B72F57AD-9358-404E-BFC6-19EF1EF0818D), 
       helpstring("IComp Interface"), 
       dual, 
       oleautomation 
       > 
       interface IComp : IDispatch { 
          <id(0x00000001), helpstring("method M1")> 
          HRESULT M1( 
                      <in> unsigned char vui1,  
                      <in> short vi2,  
                      <in> unsigned short vui2,  
                      <in> long vi4,  
                      <in> unsigned long vui4,  
                      <in> int vint,  
                      <in> unsigned int vuint,  
                      <in> VARIANT_BOOL vboolean,  
                      <in> single vr4,  
                      <in> double vr8,  
                      <in> CURRENCY vfixed,  
                      <in> DATE vdateTime,  
                      <in> BSTR vstring); 
          }; 
       }; 
    

Pass Messages to BizTalk

To allow messages to pass from the TIBCO messaging transport to BizTalk, you must create an incoming COM component port in BizTalk and then configure the service component of the adapter to write messages into the port.

Creating an incoming "COM component" port in BizTalk

  1. Start the BizTalk Orchestration Designer.
  2. Open the .skv file and select the Business Process tab.
  3. From the Implementation palette, drag a COM component port into the right hand panel. This displays the COM Component Binding Wizard.

  4. Enter a name for the port and click Next.

  1. On the Static or Dynamic Communication page, select the No Instantiation radio button and click Next.

  1. On the Interface Information page, select the IComp interface to associate it with the port and click Next. The COM Component Binding Wizard closes.

  1. Drag the right-hand connector from an Action shape to the left-hand connector of the port. This displays the Method Communication Wizard.

  2. Select the Wait for a synchronous method call radio button and click Next.

  1. Click Next to skip the Message Information page.
  2. On the Message Specification Information page, select the M1 method on the COM interface to define the BizTalk message format. The type information from the parameters of the method is used to define the message format.

  1. Click Finish. The Action shape is now connected to the incoming port.

  2. If you select the Data tab in the Orchestration Designer, you will see the message format displayed.

  3. Compile the .skv file into an .skx file.

Configuring the Service Component of TIBCO Adapter for COM

  1. Start TIBCO Designer and open the service instance.

  2. Click on either a Request Response or a Publication endpoint and then select Resources > Edit Extended Properties.

  3. Add a string (abc) extended property named monikerDisplayName (case sensitive) with the appropriate value for the BizTalk sked moniker, then click Apply.
  4. The syntax for the BizTalk sked moniker is:

    monikerDisplayName=sked://<hostname><!groupmanager>/<filepath>/<portname>

    For example, in the screen above, the following string extended property was added:

    monikerDisplayName=sked:///C:\Program Files\Microsoft BizTalk Server\Tutorial\Schedule\Lab\Buyer1.skx/Port_1

    Here filepath is the path to the BizTalk .skx file that contains the compiled BizTalk schedule, and portname is the name of the incoming port in that schedule. When the service component of the adapter starts, it will use the sked moniker to create a COM interface. Then, when the service component makes a call through a method on that interface, BizTalk will intercept the call, transform the data passed as parameters into a BizTalk message, and hand the message over to the incoming port.

Pass BizTalk Messages to TIBCO Messaging Transport

To allow BizTalk messages to pass to TIBCO messaging transport, you must create an outgoing COM component port in BizTalk.

  1. With the same .skv file open in BizTalk Orchestration Designer, select the Business Process tab.
  2. From the Implementation palette, drag a COM component port into the right-hand panel. This will display the COM Component Binding Wizard.
  3. Enter a name for the port and click Next.

  1. On the Static or Dynamic Communication page, select the Static radio button and click Next.

  1. On the Class Information page, select the From a moniker radio button, enter a tibco or tibcos moniker, and click Next.

  1. On the Interface Information page, select the IComp interface to associate it with the port. Click Next.

  1. On the Advanced Port Properties page, set any advanced properties you want and click Finish. The COM Component Binding Wizard closes.
  2. Drag the right-hand connector from an Action shape to the left-hand connector of the port. The Method Communication Wizard displays.
  3. Select the Initiate a synchronous method call radio button and click Next.

  1. Press Next to skip the Message Information page.
  2. On the Message Specification Information page, select M1 on the COM interface to define the BizTalk message format and click Finish.
  3. The type information from the parameters of the method is used to define the message format. The Action shape is now connected to the outgoing port.

  1. (Optional) If you select the Data tab in the Orchestration Designer, you will see the outgoing message format displayed.
  2. Connect the fields in the incoming message to the required fields in the outgoing message.

  3. Compile and save the .skv file into a .skx file.

Microsoft BizTalk server 2004(beta) does not support a port implementation directly using a COM component. Therefore, the section on Creating an incoming "COM component" port in BizTalk for passing messages to Microsoft BizTalk is not applicable for the BizTalk Server 2004 (beta) release. Due to this limitation, the adapter cannot directly talk to the BizTalk Server 2004 (beta) release.


TIBCO Adapter™ for COM User’s Guide
Software Release 5.3, September 2005
Copyright © TIBCO Software Inc. All rights reserved
www.tibco.com