This section describes, in more detail, the components of WebSphere Partner Gateway and shows you the various points at which you can (or must) change the system-supplied behavior of the components for processing a business document.
You use handlers to change the system-supplied behavior of targets, gateways, fixed workflow steps, and actions. There are two types of handlers--those supplied by WebSphere Partner Gateway and those that are user-defined. See the Programmer Guide if you want information about creating handlers.
After a handler is created, you upload it to make it available. You upload only user-defined handlers. The handlers supplied by WebSphere Partner Gateway are already available.
The sections that follow describe the processing points at which you can specify handlers.
Targets have three configuration points for which handlers can be specified--Preprocess, SyncCheck, and Postprocess.
The processing occurs in the following order:
The steps are described in the following sections:
The Preprocess step is generally used for any processing on the document that needs to be accomplished before the document can be processed by the Document Manager. For example, if you will be receiving multiple ROD documents in a single file, you configure the ROD splitter handler when you define the target. The ROD splitter, along with two other system-supplied splitters, are available for you to use when you set up a target. If you create additional handlers for the preprocess step, those handlers are also available.
See Preprocess for information about configuring the Preprocess configuration point.
SyncCheck is used to determine whether WebSphere Partner Gateway should process the document synchronously or asynchronously. For example, in the case of AS2 documents received over HTTP, it determines whether an MDN (message disposition notification) should be returned synchronously over the same HTTP connection. WebSphere Partner Gateway supplies a variety of handlers for synchronous checking. The list of handlers varies, depending on the transport associated with the target.
SyncCheck applies only to those transports (such as HTTP, HTTPS, and JMS) that support synchronous transmission.
See SyncCheck for information about configuring the SyncCheck configuration point.
Postprocessing is used for processing the response document that the hub sends as the result of a synchronous transaction.
See Postprocess for information about configuring the Postprocess configuration point.
Documents received by targets are picked up by the Document Manager from the common file system for further processing. The Document Manager uses participant connections to route the documents. All documents flowing through the Document Manager go through a series of workflows: fixed inbound workflow, variable workflow, and fixed outbound workflow. At the end of the inbound workflow, the participant connection is determined. The participant connection specifies the action to perform on this document. After executing the variable workflow, the Document Manager executes the fixed outbound workflow on this document.
Figure 9 shows the path that a document such as a RosettaNet PIP or a Web service would take. Some documents, however, require several configured flows. For example, an EDI interchange can consist of multiple transactions. The first flow uses an action to de-envelope the set of individual transactions. Each of these transactions is reintroduced and processed in its own configured flow.
The Inbound fixed workflow consists of the standard set of processing steps performed on all documents coming into the Document Manager from a Receiver. The workflow is fixed because the number and types of steps are always the same. Through user exits, however, you can provide customized handlers for processing the following steps: Protocol Unpackaging and Protocol Processing. The last step of inbound fixed workflow performs participant connection lookup, which determines the variable workflow that executes for this business document.
For example, if an AS2 message is received, the message is decrypted, and the sender and receiver business IDs are retrieved. The inbound fixed workflow steps convert the AS2 document into plain text for further processing by WebSphere Partner Gateway and extract information to determine the action for the message.
During Protocol Unpackaging, a document is unpackaged so that it can be further processed. This process can include decryption, decompression, signature verification, extraction of routing information, user authentication, or business document parts extraction.
WebSphere Partner Gateway provides handlers for RNIF, AS, Backend Integration, and None packaging. If handlers for other packaging types are necessary, they can be developed as user exits. Refer to the Programmer Guide for information about writing user exits.
You cannot modify the Protocol Unpackaging step; however, you can add business logic to the step by adding handlers.
See Configuring fixed workflows for information about configuring this step.
Protocol Processing stepProtocol Processing involves determining protocol-specific information, which might include parsing the message to determine routing information (such as the sender ID and the receiver ID), protocol information, and document flow information. WebSphere Partner Gateway provides processing for a variety of protocols, as listed in Protocol processing handlers. Processing for other protocols--for example, CSV (comma-separated value)--can be provided with a user exit.
You cannot modify the Protocol Processing step; however, you can add business logic to the step by adding handlers.
See Configuring fixed workflows for information about configuring this step.
You can use the default handler that applies to the protocol for your document, or you can specify a different handler for the Protocol Unpackaging and Protocol Processing fixed workflow steps.
The next step in the processing sequence occurs based on the actions that have been set up for the document exchange. Actions consist of a variable number of steps that can be performed on the document. Examples of actions are validation of a document (so that it conforms to a particular set of rules) and transformation of the document to the format required by the recipient.
If the document has no specific steps required, it can use the system-supplied Pass Through action, which makes no changes to the document.
You cannot modify a system-supplied action. You can, however, create an action (and add handlers to the configured list) or copy a system-supplied action and then modify the list of handlers.
See Configuring actions for information about creating or copying a system-supplied action or configuring a user-defined action.
The Outbound Fixed Workflow consists of one step--the packaging of the document with its protocol information. For example, if a document has been set up to be received by a back-end application using Backend Integration packaging, certain header information is added to the document before it is passed to the gateway.
WebSphere Partner Gateway provides handlers for a variety of packages and protocols, as listed in Outbound workflow. If other packaging handlers are required, they can be developed as user exit steps. Typically these steps take care of one or more of the following processes:
You cannot modify the Protocol Packaging step; however, you can add business logic to the step by adding handlers.
See Configuring fixed workflows for information about configuring this workflow step.
After the document leaves the Document Manager, it is sent, from the Gateway, to the intended recipient. The Gateway has two configuration points--Preprocess and Postprocess.
Preprocess affects the processing of a document before it is sent to the recipient. (Process is the actual sending of the document.) No handlers are supplied by the system to configure the Preprocess step; however, you can upload a user-defined handler.
Postprocess acts on the results of the document transmission (for example, on the response it receives from the recipient during a synchronous transmission). No handlers are supplied by the system to configure the Postprocess step; however, you can upload a user-defined handler.
See Configuring handlers for information about configuring the Preprocess and Postprocess steps.