Skip to main content

Meet the experts: Dave Mulley on WebSphere Partner Gateway

Dave Mulley (dmulley@us.ibm.com), IT Specialist, IBM
Photo: Dave Mulley
Dave Mulley is a Software Engineer on the IBM Software Services for WebSphere Enablement team. He focuses on Process and Business Integration using products like WebSphere Process Server, WebSphere Partner Gateway, and WebSphere Message Broker. Dave has written tutorials and articles for developerWorks on WebSphere Partner Gateway.

Summary:  This question and answer article features WebSphere® consultant Dave Mulley on WebSphere Partner Gateway and WebSphere Process Server.

Date:  22 Feb 2006
Level:  Intermediate
Activity:  295 views

Introduction

WebSphere consultant Dave Mulley answers your questions on integration between WebSphere Partner Gateway and WebSphere Process Server, and any questions about WebSphere Partner Gateway architecture, installation, configuration, and troubleshooting. WebSphere Partner Gateway is a business-to-business gateway that enables companies to connect large numbers of trading partners into their business, extending their internal integration beyond the enterprise for real-time business integration. WebSphere Partner Gateway supports document exchanges using a variety of protocols and formats including HTTP and EDI. For more information, see WebSphere Partner Gateway and developerWorks WebSphere Business Integration zone.

Question: I am new to WebSphere Partner Gateway (hereafter called Partner Gateway) and would like to know how to get started.

Answer: There are a number of excellent resources that are available to you at developerWorks. To get started, you can refer to these resources:

Question: I need to know the configuration of Covast OFTP Adapter with WebSphere Partner Gateway.

Answer: Normally, the configuration required to integrate WebSphere Partner Gateway with another product is achieved by using JMS and is a loosely-coupled type of integration. However, Covast OFTP Adapter for WebSphere Partner Gateway (OFTP Adapter) is different. During the installation of the OFTP Adapter, two new Transport Type definitions are loaded into the Partner Gateway database. You can use one of the new Transport Type definitions to create an OFTP Target to receive documents from a trading partner via either X.25 or ISDN. You can use the other new Transport Type definition to create an OFTP Gateway to send documents to a trading partner via either X.25 or ISDN. A whitepaper on the Covast Web site, OFTP Adaptor for IBM WebSphere Partner Gateway, provides detailed descriptions of each of the configurable attributes that are required by the OFTP Targets and OFTP Gateways.

Question: I am sending a document from a backend application to Partner Gateway over JMS, which I want to be sent via FTP to a trading partner. I want to be able to specify the name of the file that is sent over FTP. How do I do this?

Answer: You will need to use Backend Integration packaging between the backend application and Partner Gateway and must have installed WebSphere Partner Gateway Fix Pack 2 (or newer). Place the filename that you want to use as the output file name in a JMS property called x-aux-in-file-name. This attribute is part of Backend Integration packaging, but it is not documented in the Information Center. If you are using WebSphere Process Server as your backend application, you will need to manually add a new attribute to the BCG_PackagingHeaders Business Object with the name of x-aux-in-file-name. The JMS property values will be read by the JMS Target and placed in the document meta data. The FTP Gateway should be configured with the Unique File Name setting turned OFF. It will then use the filename from the x-aux-in-file-name as the file name of the file that it FTP's to the trading partner.

Question: I am trying to pass JMS messages with Backend Integration packaging from WebSphere Process Server to Partner Gateway using MQ Link, but Partner Gateway is trying to process the incoming message as if it has a packaging of NONE. I have populated the attributes in the BCG_PackagingHeaders Business Object, but they seem to be getting lost before the JMS message gets to Partner Gateway. What is happening here?

Answer: A JMS message is made up of a JMS header, JMS properties, and a JMS body. The JMS properties are used to hold useful information that could not be placed in the JMS body (which is the message payload). When a JMS message is placed on a WebSphere MQ queue, the JMS properties are held in a special WebSphere MQ header called the RFH2 header because a WebSphere MQ message has no equivalent to JMS properties portion of a JMS message. With that said, I am assuming that you are using the com.ibm.bcg.dataBinding.BCGBackendIntegrationJMSDataBindingImpl. Data Binding on your JMS Import as the WebSphere Process Server default data binding for JMS Imports will not create the required JMS properties (the Backend Integration packaging values are actually JMS properties on the JMS message) on the JMS message. The problem you are hitting is most likely a default value on all foreign queue definitions on the service integration bus when the MQ Link is being used to transmit messages to a WebSphere MQ queue. This default is that the RFH2 header should be stripped from the JMS message before it is passed to WebSphere MQ, which will result in the Backend Integration packaging values being lost. To override the default, select the foreign queue destination in the WebSphere Administrative console and create a new context property like the one shown in Figure 1.


Figure 1. Context Properties Dialog
Context Properties Dialog

Question: How can I use a File Directory Target to get a flat file containing binary data into Partner Gateway?

Answer: Unfortunately, the File Directory Target can only handle parsable files, where the routing information is included in the file in a known format (for example, EDI or XML). It has no ability to handle binary type files that do not contain the required information. You have two options, the first is to write a pre-processing exit for the File Directory Receiver that will set the routing information required by Partner Gateway. However, this will not be flexible as the only variable that you can change is the filename to indicate the document type and partner identifiers. The other option is to use the FTP Target, which is designed to handle both parsable and binary files. The FTP Target has a pre-set directory structure that allows Partner Gateway to establish the source partner identifier. The filename is used to identify the desired target partner for binary files (for example, the filename 123456789.somefilename tells the FTP Target that the to partner identifier is 123456789. As the FTP target simply polls the directory structure in the same way that the File Directory Target does, you do not actually need an FTP Server to use the FTP Target.

Question: I want to send JMS messages between WebSphere Process Server and Partner Gateway. I see that I can use either the MQ Link to connect a WebSphere MQ Queue Manager that Partner Gateway uses to the Service Integration Bus that WebSphere Process Server uses, or I can use the Service Integration Bus for both WebSphere Proccess Server and Partner Gateway. Which option is recommended?

Answer: Service Integration Bus to Service Integration Bus communication is only available as an option when Partner Gateway has been installed into an existing WebSphere Application Server Network Deployment configuration. This is because the Service Integration Bus does not expose a client API, which would be required if Partner Gateway had been installed using the embedded server option. If the embedded server option was selected during the installation, you have only the MQ Link option available. If Partner Gateway has been installed into an existing WebSphere Application Server ND configuration, then you should definitely use the Service Integration Bus to Service Integration Bus communication option rather than add another layer of communication overhead to the configuration.

Question: Why do my MDNs take a minute to be created after a document has been received using AS2?

Answer: A separate engine from the main Document Manager engine generates the MDNs. By default, it has a poll interval that is set to 60000 milliseconds. You can modify this poll interval by changing the PollInterval entry for the ASStateEngine in the <WPGHOME>\bcghub\router\lib\config\router-was-jmx-container.xml file as highlighted below. Do not set the value to low because this will result in increased communication with the Partner Gateway database and will impact performance. 10000 is probably the smallest value that you can have without a negative impact on performance. You will need to restart the Document Manager for any changes to take effect.

<mbean name="ASStateEngine" type="Production" code="com.ibm.bcg.server.stateeng.StateEngine">
        <attribute name="WorkType">AS</attribute>
        <attribute name="NumThreads">2</attribute>
        <attribute name="WorkClassName">com.ibm.bcg.server.asstate.ASWork</attribute>
        <attribute name="PollInterval">60000</attribute>
        <attribute name="BatchSize">1</attribute>
        <attribute name="StateInstanceName">bcg</attribute>
    </mbean>

Question:: I am having trouble importing Business Objects from WebSphere Integration Developer DIS Client. I have imported the xsd file without modification from WebSphere Integration Developer and although the import completed successfully, the Overview tab shows only errors. Here is my simple xsd file:

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:boxs="http://JMSLibrary">
	<xsd:complexType name="studentType">
		<xsd:sequence>
			<xsd:element name="firstName" type="xsd:string" minOccurs="0"/>
			<xsd:element name="lastName" type="xsd:string" minOccurs="0"/>
			<xsd:element name="address1" type="xsd:string" minOccurs="0quot;/>
			<xsd:element name="address2" type="xsd:string" minOccurs="0"/>
		</xsd:sequence>
	</xsd:complexType>
</xsd:schema>

This is how the XML structure is shown on the Overview tab:


Figure 2. DIS Client Overview tab
DIS Client Overview tab

Answer: The DIS Client requires a top-level element definition in the xsd file. I have made the change shown below to the xsd file. It imports correctly and the Overview tab shows the XML structure correctly.

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"xmlns:boxs="http://JMSLibrary">
	<xsd:element name="Student" type="boxs:studentType" />
		<xsd:complexType name="studentType">
			<xsd:sequence>
				<xsd:element name="firstName" type="xsd:string" minOccurs="0"/>
				<xsd:element name="lastName" type="xsd:string" minOccurs="0"/>
				<xsd:element name="address1" type="xsd:string" minOccurs="0"/>
				<xsd:element name="address2" type="xsd:string" minOccurs="0"/>
			</xsd:sequence>
		</xsd:complexType>
</xsd:schema>


Figure 3. DIS Client Overview tab
DIS Client Overview tab

Question: How do I send an EDI-X12/ISA document out of Partner Gateway with Backend Integration packaging? I see EDI-X12 is available in the AS, None, and N/A packages, but not in the Backend Integration package.

Answer: When Partner Gateway is installed, the EDI-X12 Protocol is not included in the Backend Integration Package. You need to update the EDI-X12 Protocol to include it in the Backend Integration Package. To modify the EDI-X12 Protocol:

  1. Click on Hub Admin -> Document Flow Definitions, open Package: None, and then click the drill down icon next to Protocol: EDI-X12 as shown in Figure 4.

    Figure 4. Locating the EDI-X12 Protocol on the Manage Document Flow Definitions page
    Locating the EDI-X12 Protocol on the Manage Document Flow Definitions page

  2. Then click Add New Context as shown in Figure 5:

    Figure 5. Document Flow Definition contexts
    Document Flow Definition contexts

  3. Select Package: Backend Integration as shown in Figure 6 and Save the new definition.

    Figure 6. Adding the Backend Integration Package
    Adding the Backend Integration Package

  4. It is also necessary to update the ISA Document Flow using the same method as above. Locate Package: None, Protocol: EDI-X12, Document Flow: ISA and drill down as shown in Figure 7:

    Figure 7. Locating the ISA Document Flow on the Manage Document Flow Definitions page
    Locating the ISA Document Flow on the Manage Document Flow Definitions page

  5. Click Add New Context as shown in Figure 8:

    Figure 8. Document Flow Definition contexts
    Document Flow Definition contexts

  6. Select Package: Backend Integration, Protocol: EDI-X12 as shown in Figure 9 and Save the new definition.

    Figure 9. Adding the Backend Integration/EDI-X12 Protocol
    Adding the Backend Integration/EDI-X12 Protocol

Question: How do I turn on tracing for the DIS mapping?

Answer:

  1. Open the <WPGHOME>\bcghub\router\lib\config\ediparms.properties file.
  2. Uncomment the required lines for the components that you wish to trace. I would recommend that you uncomment the following line, traceLevel.All=2, because this will trace all the components of the translation engine.
  3. You also need to turn on tracing for the Document Manager by opening the <WPGHOME>\bcghub\router\lib\config\router-was.logging.properties file, and changing the log4j.rootCategory=error, RollingFile line to read log4j.rootCategory=debug, RollingFile, and then restarting the Document Manager.

The trace messages will now be written to the <WPGHOME>\bcghub\was\profiles\bcgdocmgr\logs\bcgdocmgr\bcg_router.log file as the Document Manager processes documents.


Resources

About the author

Photo: Dave Mulley

Dave Mulley is a Software Engineer on the IBM Software Services for WebSphere Enablement team. He focuses on Process and Business Integration using products like WebSphere Process Server, WebSphere Partner Gateway, and WebSphere Message Broker. Dave has written tutorials and articles for developerWorks on WebSphere Partner Gateway.

Comments (Undergoing maintenance)



Trademarks  |  My developerWorks terms and conditions

Help: Update or add to My dW interests

What's this?

This little timesaver lets you update your My developerWorks profile with just one click! The general subject of this content (AIX and UNIX, Information Management, Lotus, Rational, Tivoli, WebSphere, Java, Linux, Open source, SOA and Web services, Web development, or XML) will be added to the interests section of your profile, if it's not there already. You only need to be logged in to My developerWorks.

And what's the point of adding your interests to your profile? That's how you find other users with the same interests as yours, and see what they're reading and contributing to the community. Your interests also help us recommend relevant developerWorks content to you.

View your My developerWorks profile

Return from help

Help: Remove from My dW interests

What's this?

Removing this interest does not alter your profile, but rather removes this piece of content from a list of all content for which you've indicated interest. In a future enhancement to My developerWorks, you'll be able to see a record of that content.

View your My developerWorks profile

Return from help

static.content.url=http://www.ibm.com/developerworks/js/artrating/
SITE_ID=1
Zone=WebSphere
ArticleID=104431
ArticleTitle=Meet the experts: Dave Mulley on WebSphere Partner Gateway
publish-date=02222006
author1-email=dmulley@us.ibm.com
author1-email-cc=

My developerWorks community

Tags

Help
Use the search field to find all types of content in My developerWorks with that tag.

Use the slider bar to see more or fewer tags.

Popular tags shows the top tags for this particular content zone (for example, Java technology, Linux, WebSphere).

My tags shows your tags for this particular content zone (for example, Java technology, Linux, WebSphere).

Use the search field to find all types of content in My developerWorks with that tag. Popular tags shows the top tags for this particular content zone (for example, Java technology, Linux, WebSphere). My tags shows your tags for this particular content zone (for example, Java technology, Linux, WebSphere).

Special offers