|
|
Understanding the Sample
Note: We strongly recommend that you run the sample before reading this section. For instructions, see Setting Up and Running the Sample. The sample code described in this section is available in the \samples\wlis directory of your WebLogic Integration installation.
The sample application automates a number of business processes, integrates back-end enterprise information systems (EIS), and deploys a supply-chain hub that connects business partners. This section describes how this sample integrated solution addresses the supply-chain challenge experienced by our hypothetical enterprise, General Control Systems (GCS). Specifically, it includes the following topics:
Overview
In our sample scenario, General Control Systems (GCS) decides to implement a WebLogic Integration solution to its supply-chain challenge. What is the first step?
GCS begins by analyzing how it will use WebLogic Integration to perform the following tasks:
The remainder of this section explains how WebLogic Integration enables GCS to perform these tasks.
Model Business Processes
WebLogic Integration provides the tools required to manage business processes:
Manage B2B Integration
WebLogic Integration supports communication with external trading partners over the Internet. Specifically, it supports the XOCP, RosettaNet (1.1 and 2.0), and Ariba cXML business protocols for sending and receiving XML messages.
A B2B integration BPM plug-in extends the WebLogic Integration Studio so the Studio can be used to define collaborative workflows, that is, workflows that exchange messages with external trading partners.
Integrate New and Existing Systems
WebLogic Integration supports the integration of new Web-based front-end systems with existing enterprise information system (EIS) applications through the use of adapters. Application integration adapters can be broadly categorized as follows:
Application integration adapters are configured using a Web browser interface. Business events that flow through application integration adapters are defined as XML Schema Definitions (XSDs) in the WebLogic Integration repository.
An application integration BPM plug-in extends the WebLogic Integration Studio so the Studio can be used to define processes that:
Handle Heterogeneous Data Formats
XML is the message format used in WebLogic Integration systems. The WebLogic Integration framework, however, makes it easy to integrate WebLogic Integration applications with environments in which a binary message format is used.
WebLogic Integration supports the following types of data integration:
XSL stylesheets can be created manually or by using the Contivo Analyst mapping tool that is bundled with the WebLogic Integration product. Stylesheets are stored in the WebLogic Integration repository.
Transformations are executed at run time: an input message is assigned to a workflow variable; the process engine references the XSL stylesheet in the repository; and the output message is assigned to another workflow variable.
The following sections describe how the components of WebLogic Integration work together to build and deploy this sample application.
B2B Integration
The definition and management of the relationships between the trading partners that participate in the e-business transactions (in the roles of the buyer and suppliers for this scenario) is fundamental to the development of this integrated solution. The data to define and administer trading partners is stored in the WebLogic Integration repository, and WebLogic Integration provides tools and processes for the effective management of dynamic and diverse trading partner relationships.
An exhaustive discussion of how to configure your B2B integration environment is beyond the scope of this document. However, this section briefly describes the WebLogic Integration repository data that is used in the sample application, how it is loaded for the sample, and how you can view the data and monitor the progress of the sample's business conversations.
For information about B2B integration and instructions for configuring the WebLogic Integration environment to support it, see Introducing B2B Integration and Administering B2B Integration, respectively.
This section includes the following topics:
Loading the Repository Data
The data required by the sample for integrating the trading partners is bulk loaded into the WebLogic Integration repository when you run the RunSamples script during the sample setup (see Running the Sample).
The RunSamples script loads the repository with the B2B configuration data contained in the following XML files:
D:\bea\wlintegration2.1\dbscripts
The SystemRepData.xml file contains system data. The elements used by this sample include:
D:\bea\wlintegration2.1\samples\wlis\lib
This BulkLoaderData.xml file contains data specific to the WebLogic Integration sample. It describes the following elements:
For details about each of these data elements, see the next section, Understanding the Repository Data.
Understanding the Repository Data
This section highlights important information about the following data elements that are bulk loaded to the WebLogic Integration repository for the sample application:
Note: As described in Loading the Repository Data, data from two XML files is imported into the WebLogic Integration repository to support the sample application. You can bulk load configuration data or enter it through the WebLogic Integration B2B Console. You can also access and configure bulk-loaded data using the B2B Console. For more information, see Using the WebLogic Integration B2B Console.
Business Protocol Definitions
The SystemRepData.xml file contains system data, including definitions for all the business protocols supported by WebLogic Integration: XOCP, RosettaNet, and cXML. The WebLogic Integration sample application uses only XOCP. The following excerpt from the SystemRepData.xml file shows the XOCP business protocol definitions.
Listing 3-1 XOCP Business Protocol Definitions in the SystemRepData.xml File
<!-- XOCP BUSINESS PROTOCOL DEFINITIONS -->
<business-protocol-definition
name="XOCP-SPOKE"
business-protocol-name="XOCP"
protocol-version="1.1"
endpoint-type="SPOKE">
<java-class>com.bea.b2b.protocol.xocp.XOCPSpokeProtocol</java-class>
<decoder>XOCP-Decoder</decoder>
<encoder>XOCP-Encoder</encoder>
</business-protocol-definition>
<business-protocol-definition
name="XOCP-Hub"
business-protocol-name="XOCP"
protocol-version="1.1"
endpoint-type="HUB">
<java-class>com.bea.b2b.protocol.xocp.XOCPHubProtocol</java-class>
<decoder>XOCP-Decoder</decoder>
<system-router>XOCP-System-Router</system-router>
:
:
<system-router>XOCP-Router-Enqueue</system-router>
<system-filter>XOCP-System-Filter</system-filter>
:
<encoder>XOCP-Encoder</encoder>
:
:
</business-protocol-definition>
In the preceding listing, note the following:
For details about configuring business protocol definitions, see Configuration Requirements in Administering B2B Integration and Configuring Trading Partners in Online Help for the WebLogic Integration B2B Console.
Logic Plug-Ins
Logic plug-ins are Java classes that can intercept and process business messages at run time. Each business protocol is associated with standard router and filter logic plug-ins.
The SystemRepData.xml file contains system data, including the WebLogic Integration logic plug-ins for XOCP, RosettaNet, and cXML business protocols. This sample uses the XOCP logic plug-ins only.
Table 3-1 XOCP-Specific Logic Plug-Ins
For details about developing logic plug-ins and processing messages through the WebLogic Integration B2B engine, see Programming Logic Plug-Ins for B2B Integration.
Trading Partners
The WebLogic Integration sample scenario involves three business partners: a buyer (General Control Systems) and two suppliers. For each business partner, a trading partner is configured in the BulkLoaderData.xml file. The following trading partners are defined for the sample: WLIS_Buyer, WLIS_SupplierOne, and WLIS_SupplierTwo.
Because these trading partners communicate using the XOCP business protocol, General Control Systems must define its WebLogic Integration system as hub-and-spoke configuration. (See Getting Started with B2B integration in Introducing B2B Integration for details about configuring B2B integration.) To that end, the BulkLoaderData.xml file defines a fourth trading partner: WLIS_Hub.
The WLIS_Hub trading partner acts as an intermediary. It is responsible for mediating messages between the spoke trading partners: WLIS_Buyer, WLIS_SupplierOne, and WLIS_SupplierTwo. The WLIS_Hub trading partner is not the sender or receiver of a business message, but it acts as the proxy buyer and proxy supplier, at different times during the transaction.
Each of the three trading partners—WLIS_Buyer, WLIS_SupplierOne, and WLIS_SupplierTwo—has a collaboration agreement with the WLIS_Hub trading partner. The WLIS_Hub trading partner is responsible for linking collaboration agreements. Such linking is essential, for example, when a message arrives as part of one collaboration agreement and must be routed to another trading partner as part of another collaboration agreement. Collaboration agreements that use the same delivery channel—the channel defined for the WLIS_Hub trading partner—are linked. For details about the collaboration agreements in this scenario, see Collaboration Agreements.
Each trading partner element is characterized by various attributes and subelements, some of which contain simple identification information, such as name, email, phone, and fax. Other trading partner configuration information is described in the following table.
Table 3-2 Trading Partner Configuration
Note: See the BulkLoaderData.xml file for the sample's trading partner configuration.
Conversation Definitions
The BulkLoaderData.xml file contains two XOCP conversation definitions, one each for the Query Price and Availability (QPA) and the Purchase Order (PO) conversations. There are two roles—buyer and supplier—for each conversation. Each role references the following:
wlpi-template="WLIS_SupplierQPA"
process-implementation wlpi-org="ORG1"
Note: The BPM component of WebLogic Integration was formerly known as WebLogic Process Integrator (WLPI). You may still see references to WebLogic Process Integrator or WLPI, as in the names of the template and organization shown here.
The workflow template, in turn, references the conversation definition to which it applies. (For example, see the reference to a conversation in Figure3-12, which shows properties for one of the public workflows used in this sample).
For details about the workflows used to implement this sample, see Business Process and Workflow Modeling.
Organizations represent different business entities, geographical locations, or any other classifications that are relevant to the particular business of the company. For details about BPM organizations, see Configuring the Security Realms in Programming BPM Client Applications.
The following listing is an excerpt from the BulkloaderData.xml file. It defines the WLIS_QPAConversation.
Listing 3-2 Conversation Definition in the BulkLoaderData.xml File
...
<conversation-definition
name="WLIS_QPAConversation"
version="1.1"
business-protocol-name="XOCP"
protocol-version="1.1">
<role
name="Buyer"
wlpi-template="WLIS_BuyerQPAPublic">
<process-implementation wlpi-org="ORG1" />
</role>
<role
name="Supplier"
wlpi-template="WLIS_SupplierQPAPublic">
<process-implementation wlpi-org="ORG1" />
</role>
</conversation-definition>
...
Collaboration Agreements
Six collaboration agreements are used in this sample: three in the QPA conversation and three in the PO conversation. For each conversation, collaboration agreements are defined between the following pairs of business entities:
The following figure illustrates the collaboration agreements among trading partners who participate in the QPA conversation (WLIS_QPAConversation).
Figure 3-1 Collaboration Agreements Among Trading Partners in the QPA Conversation
The following figure illustrates the collaboration agreements among trading partners who participate in the PO conversation (WLIS_POConversation). Figure 3-2 Collaboration Agreements Among Trading Partners in the PO Conversation
Notice the following details in the preceding figures:
For example, when the WLIS_Hub trading partner receives a QPA message from WLIS_Buyer, it is acting as the proxy supplier in the QPA_1 collaboration agreement. It then changes roles and becomes the proxy buyer for the QPA_2 and QPA_3 collaboration agreements.
The following listing is an excerpt from the BulkLoaderData.xml file. It describes the collaboration agreement between WLIS_Hub and WLIS_Buyer.
Listing 3-3 Collaboration Agreement in the BulkLoaderData.xml file
...
<collaboration-agreement
name="WLIS_QPAConversation|1.1|WLIS_Buyer|WLIS_Hub"
global-identifier="WLIS_QPAConversation|1.1|WLIS_Buyer|WLIS_Hub
version="1.1"
status="ENABLED"
conversation-definition-name="WLIS_QPAConversation"
conversation-definition-version="1.1">
<party
trading-partner-name="WLIS_Buyer"
party-identifier-name="WLIS_BuyerPartyId"
delivery-channel-name="WLIS_BuyerDeliveryChannel"
role-name="Buyer"/>
<party
trading-partner-name="WLIS_Hub"
party-identifier-name="WLIS_HubPartyId"
delivery-channel-name="WLIS_HubDeliveryChannel"
role-name="Supplier"/>
</collaboration-agreement>
...
Using the WebLogic Integration B2B Console
WebLogic Integration allows you to bulk load configuration data or enter it through the WebLogic Integration B2B Console. You do not need to run the B2B Console when you run the WebLogic Integration sample, but you can use it to view the repository data that is bulk loaded for the sample (see Loading the Repository Data). You can also use the B2B Console to monitor the ongoing conversations while you are running the sample.
Start the WebLogic Integration B2B Console by completing the procedure appropriate for your platform:
Note: If you have not already done so, run the WebLogic Integration sample as described in Setting Up and Running the Sample.
Choose Start
a. Open a command window.
b. Go to the bin directory in the directory in which you installed WebLogic Integration. For example, if WebLogic Integration is installed in the default location, enter the following:
cd \bea\wlintegration2.1\bin
c. Start the B2B Console by entering:
startB2bconsole
http://localhost:7001/b2bconsole
The following figure shows the WebLogic Integration B2B Console with the WebLogic Integration sample data loaded.
Figure 3-3 WebLogic Integration B2B Console Displaying Sample Data
See Online Help for the WebLogic Integration B2B Console and Administering B2B Integration for details about using the WebLogic Integration B2B Console to configure B2B integration. See Working with the Bulk Loader in Administering B2B Integration for details about the Bulk Loader.
Business Process and Workflow Modeling
This section provides a brief introduction to the business process management (BPM) functionality provided by WebLogic Integration, followed by instructions for starting and using the Studio, and descriptions of the two business processes implemented by the WebLogic Integration sample: Query Price and Availability (QPA) and Purchase Order (PO). It includes the following topics:
Introduction to BPM
Workflows that implement the roles assigned to trading partners in a conversation definition (see Conversation Definitions) are referred to as collaborative workflows.
A workflow template represents a workflow, and combines various workflow template definitions (versions) of its implementation. Workflow templates are designed and edited in the WebLogic Integration Studio. Several BPM plug-ins extend the functionality of the Studio:
In this sample scenario, trading partners implement both private and collaborative workflows. Private workflows work in conjunction with the collaborative workflows, and implement local processes for the trading partners. Local and private processes are not necessarily dictated by the conversation definition. For example, when a trading partner starts a conversation, that trading partner's private workflow can start the collaborative workflow to initiate the conversation.
The following sections describe the implementation of the business processes on the buyer-side and supplier-side of the sample business transaction. Key workflow design elements, tasks, and events are highlighted.
Using the WebLogic Integration Studio
The WebLogic Integration Studio allows you to design new workflows and monitor running workflows using a familiar flowchart paradigm. You are not required to run the Studio when you run the WebLogic Integration sample, but you may find it useful for viewing the details of any workflow or workflow node, and for learning how nodes are defined and configured for this sample. You can also use the Studio to monitor the workflows as you run the sample.
This section provides procedures for starting and using the Studio, and a list of components used by the sample to manage business processes.
Launching the Studio
Launch the Studio by completing the procedure appropriate for your platform:
a. Choose Start
b. Log on to the Studio (user: wlpisystem; password: wlpisystem).
a. Open a command window.
b. Go to the bin directory in the directory where you installed WebLogic Integration. For example, if WebLogic Integration is installed in the default location, enter the following:
cd \bea\wlintegration2.1\bin
c. Execute the studio command by entering:
studio
d. Log on to the Studio (user: wlpisystem; password: wlpisystem).
cd BEA_Home/wlintegration2.1/bin
. ./studio
Viewing Workflow Templates in the Studio
To view a workflow template and its properties in the Studio, complete the following procedure:
Note: You can also expand a particular workflow template definition to display folders containing the Tasks, Decisions, Events, Joins, Starts, Dones, and Variables for that workflow template definition.
See Using the WebLogic Integration Studio for complete details about the Studio tools and functionality.
BPM Components Used in the Sample
Workflow templates and other data required by the Studio and process engine for this sample application are loaded into the WebLogic Integration repository, via the workflow.jar file, when you configure the sample. Imported components include those listed in the following table.
Table 3-3 Components Imported to the WebLogic Integration Repository
QPA Business Process
Due to the supply shortage of metal boxes, GCS (the buyer trading partner) sends a QPA message for such boxes to selected suppliers. The following diagram illustrates the flow of events for the QPA business process.
Figure 3-4 Process Flow in the QPA Business Process
The following sequence summarizes the events illustrated in the preceding figure:
Note: The preceding figure shows a high-level view of the QPA business process. Each side of the process is implemented by a public (collaborative) and a private workflow. The following sections describe these workflows:
Overview of the QPA Implementation
In this scenario, each trading partner implements a private and a public workflow for the QPA process. The following five workflow templates are used in this sample's QPA process.
Table 3-4 Workflows for the Sample QPA Process
WebLogic Integration manages the business conversations and collaboration agreements between business partners, and it automates the business message exchange between the buyer and suppliers. The workflows are referenced in the collaboration agreements and conversations, as described in Understanding the Repository Data.
This sample uses JSPs and JSP tag libraries to initiate the QPA process and display QPA request and response data. The following figure illustrates the data flow among the trading partners involved in the QPA business transaction.
Figure 3-5 Data Flow in the QPA Business Process
The buyer-side and supplier-side implementations are discussed in more detail in Buyer-Side Implementation and Supplier-Side Implementation. The following sequence of events summarizes the data flow among trading partners and workflows:
Note: When the WLIS_Hub trading partner receives a message, it is acting as the proxy supplier in the collaboration agreement.
Note: In this step, the WLIS_Hub trading partner changes roles and becomes the proxy buyer in the collaboration agreements between itself and the suppliers.
Each supplier's public workflow is triggered by receiving the XOCP message. In this scenario, WLIS_SupplierOne and WLIS_SupplierTwo share the public workflow (WLIS_SupplierQPAPublic). The public workflow extracts the QPA request XML document from the message.
Note that the WLIS_Hub trading partner acts as a routing proxy for WLIS_Buyer. When the supplier trading partners send response messages to WLIS_Hub (based on collaboration agreements between WLIS_Hub and each supplier trading partner), WLIS_Hub acts as the proxy buyer.
WLIS_Hub then changes roles to that of proxy supplier, and routes the response messages to the buyer (WLIS_Buyer), based on the collaboration agreement between WLIS_Hub and WLIS_Buyer.
This step marks the end of the QPA business process.
Buyer-Side Implementation
To implement this solution, the buyer (GCS) implements a custom client (Web user interface) to drive the sample, process messages, and exchange XML messages with the WebLogic Integration process engine, using JMS queues. GCS also implements a private workflow, to manage the buyer's back-end processes, and a public workflow that choreographs the exchange of messages in the QPA conversation. This section discusses these components:
Buyer-Side Web User Interface
Java Server Pages (JSPs) and JSP tag libraries are used to initiate the QPA process and display request and response data in your Web browser. The source files related to the QPA process can be found in the directories listed in the following table.
Table 3-5 Source Files for the QPA Process
Directory in Your WebLogic Integration Installation |
Source File |
---|---|
\samples\wlis\src\examples\wlis\tags |
|
\samples\wlis\web |
|
\samples\wlis\lib\xsl |
ProcessQPAResponse.xsl |
The Web user interface interacts with the buyer's private workflow (WLIS_BuyerQPAPrivate), as illustrated in the following figure.
Figure 3-6 Interaction Between the Web User Interface and the Buyer's Private Workflow
The following sequence of events describes the interaction illustrated in the preceding figure:
The following listing is code from the SendQPARequestTag.java file that defines the name of the JMS queue and the queue connection factory to which the XML message is posted:
Listing 3-4 SendQPARequestTag.java
//Defines the JMS connection factory.
final String JMS_FACTORY = "com.bea.wlpi.QueueConnectionFactory";
//Defines the JMS queue.
final String QUEUE = "com.bea.wlpi.EventQueue";
...
Buyer QPA Private Workflow
The WLIS_BuyerQPAPrivate workflow is initiated by the JMS message, which contains the QPA request data, sent from a JSP. The interaction of the workflow with the Web user interface is described in Buyer-Side Web User Interface.
The WLIS_BuyerQPAPrivate workflow template is shown in the following figure.
Figure 3-7 WLIS_BuyerQPAPrivate Workflow Template
The following sections define the key tasks and events at the nodes in the WLIS_BuyerQPAPrivate workflow template, shown in the preceding figure:
Figure 3-8 Application Integration Call Service Dialog Box
Note: You can examine the XML schema of the input or the response document, by clicking View Request Definition or View Response Definition, respectively. The View Definition dialog box is displayed. Click Close when finished.
Figure 3-9 Set Workflow Variable Dialog Box
Figure 3-10 Start Public Workflow Dialog Box
Note the following properties for the WebLogic Integration sample in the preceding figure:
See Listing3-3, Collaboration Agreement in the BulkLoaderData.xml file, for an excerpt from the BulkLoaderData.xml file. It describes the collaboration agreement that the process engine locates in the repository to meet the specifications defined on this Conversation tab.
Note also that the subworkflow (WLIS_BuyerQPAPublic) is invoked asynchronously at this node. If you open the Task Properties dialog box and choose Actions
See Creating Workflows for B2B Integration for more details about workflows in B2B conversations.
\samples\wlis\src\examples\wlis\common\util\Utils.java.
Buyer QPA Public Workflow
The buyer's public workflow (WLIS_BuyerQPAPublic) is initiated by the buyer's private workflow (WLIS_BuyerQPAPrivate) for the QPA business process.
The following figure shows the WLIS_BuyerQPAPublic workflow template.
Figure 3-11 WLIS_BuyerQPAPublic Workflow Template
The following sections define the key tasks and events at the nodes in the WLIS_BuyerQPAPublic workflow template, shown in the preceding figure:
Note: You must define conversation properties for workflows involved in B2B conversations, that is, for the public workflows, which are also called collaborative workflows in the WebLogic Integration environment. The WLIS_BuyerQPAPublic workflow is an example of a collaborative workflow.
To see the conversation properties for the WLIS_BuyerQPAPublic workflow template, right click the template name in the left pane of the Studio, and select Properties from the drop-down menu. The template definition dialog box shown in the following figure is displayed.
Figure 3-12 Template Definition for the WLIS_BuyerQPAPublic Workflow
Figure 3-13 Send Business Message Dialog Box
Figure 3-14 B2B Conversation: Event Node Properties
Figure 3-15 Set Workflow Variable Dialog Box
Supplier-Side Implementation
To implement this solution, the suppliers implement private workflows to manage the back-end processes, and a public workflow that choreographs the exchange of messages in the QPA conversation. This section describes the following workflows:
Supplier QPA Public Workflow
The suppliers' QPA public workflow (WLIS_SupplierQPAPublic) is initiated by the incoming message from the WLIS_Hub trading partner.
The following figure shows the WLIS_SupplierQPAPublic workflow template.
Figure 3-16 WLIS_SupplierQPAPublic Workflow Template
The following sections define the key tasks and events at the nodes in the WLIS_SupplierQPAPublic workflow template, shown in the preceding figure:
Supplier QPA Private Workflow
There are two workflow templates in this category, one for each supplier:
The templates differ only slightly from each other. We leave it as an exercise for readers to determine the difference.
The suppliers' QPA private workflows are invoked from the suppliers' QPA public workflow (WLIS_SupplierQPAPublic).
The following figure shows the WLIS_SupplierOneQPAPrivate workflow template.
Figure 3-17 WLIS_SupplierOneQPAPrivate Workflow Template
The following sections define the key tasks and events at the nodes in the WLIS_SupplierOneQPAPrivate workflow template shown in the preceding figure:
$QPARequestXML))
PO Business Process
Assume that you are the buyer in this sample scenario. After reviewing the QPA responses from the suppliers, select one of the suppliers and start the PO business process, as described in Step 6. Create the Purchase Order. The following diagram illustrates the flow of events for the PO business process.
Figure 3-18 Process Flow in the PO Business Process
The following sequence summarizes the events illustrated in the preceding figure:
Note: The preceding figure shows a high-level view of the PO business process. Each side of the process is implemented by a public and a private workflow. The following sections describe these workflows:
Overview of the PO Implementation
In this scenario, each trading partner implements a private workflow and a public workflow for the PO process. The following workflow templates are used in the sample.
Table 3-6 Workflows for the Sample PO Process
The PO implementation for this sample requires WebLogic Integration support for application integration, data integration, and management of business processes. This section describes the PO workflows, including their integration with back-end applications and heterogeneous data formats. See Application and Data Integration for more information about application integration and data integration functionality as it applies to the PO business process in this scenario.
The following figure illustrates the data flow among the trading partners involved in the PO business process.
Figure 3-19 Data Flow in the PO Business Process
For details about the buyer-side and supplier-side implementations, see Buyer-Side Implementation and Supplier-Side Implementation. The following sequence of events summarizes the data flow among trading partners, workflows, and back-end systems:
A JSP extracts the PO request information, including the party ID, unit price, quantity, and delivery date, and puts it in an XML message. The XML message is posted to the BPM JMS queue.
The WLIS_BuyerQPAPrivate workflow invokes the insertPO service on the WLISAppView.sav application view to insert the PO information into the Enterprise Information System (EIS). The EIS is simulated by an RDBMS in this sample. (The WLISAppView.sav application view, together with its services and events, is configured and deployed in WebLogic Integration when you set up the sample.)
The application view event triggers the start of the buyer's private workflow for the PO process (WLIS_BuyerPOPrivate).
The WLIS_Hub trading partner routes the message to the destination trading partner, WLIS_Buyer, based on a registered collaboration agreement between itself and WLIS_Buyer.
Note: In this step, the WLIS_Hub trading partner changes roles and becomes the proxy supplier in the collaboration agreement between itself and the buyer.
The WLIS_SupplierPOPublic workflow starts the selected supplier's private workflow (WLIS_SupplierOnePOPrivate or WLIS_SupplierTwoPOPrivate).
This step marks the end of the PO conversation.
This step marks the end of the PO business process.
Buyer-Side Implementation
The buyer (GCS) in our sample scenario implements a Web user interface to drive the business transaction, a private workflow to manage the buyer's back-end processes, and a public workflow that choreographs the message exchange in the PO conversation. The WLIS_Buyer trading partner stores its PO information in an RDBMS.
Through the use of the application integration framework provided by WebLogic Integration, the workflows in the PO business process can integrate with the RDBMS. To support application integration, an application view (WLISAppView.sav) is deployed for this sample when you set up and configure the samples domain. (The sample domain setup is described in Step 1A: Invoke the RunSamples Script.)
This section discusses the following components of the buyer-side PO business process:
Buyer-Side Web User Interface
The interaction between the Web browser and the buyer-side workflows for the buyer-side implementation is similar to that for the QPA business process—Java Server Pages (JSPs) and JSP tag libraries are used to initiate the PO process and display request and response data in your Web browser. The source files related to the PO business process can be found in the directories listed in the following table.
Table 3-7 Source Files for the PO Process
Directory in your WebLogic Integration Installation |
Source Files |
---|---|
\samples\wlis\src\examples\wlis\tags |
|
\samples\wlis\web |
|
\samples\wlis\lib\xsl |
Buyer PO Private Workflow
The WLIS_BuyerPOPrivate workflow performs the following key tasks:
The following figure shows the WLIS_BuyerPOPrivate workflow template.
Figure 3-20 WLIS_BuyerPOPrivate Workflow Template
The following sections define the key tasks and events at the nodes in the WLIS_BuyerPOPrivate workflow template, shown in the preceding figure:
Figure 3-21 Start Properties Dialog Box
Note: You can examine the XML schema of the event document by clicking View Definition in the Start Properties dialog box.
\samples\wlis\src\examples\wlis\common\util\Utils.java.
Figure 3-22 Start Public Workflow Dialog Box
Note the following parameters for the Start Public Workflow action shown in the preceding figure:
Buyer PO Public Workflow
The primary task of the WLIS_BuyerPOPublic workflow is to send and receive the XOCP business messages in the purchase order conversation (WLIS_POConversation).
The following figure shows the WLIS_BuyerPOPublic workflow template.
Figure 3-23 WLIS_BuyerPOPublic Workflow Template
The following sections define the key tasks and events at the nodes in the WLIS_BuyerPOPublic workflow template, shown in the preceding figure:
Supplier-Side Implementation
In this scenario, each supplier implements a private workflow to integrate its back-end processes, and a public workflow to choreograph the exchange of messages in the PO conversation. This section describes the following workflows:
Supplier PO Public Workflow
The PO public workflow (WLIS_SupplierPOPublic) is started on receipt of an XOCP business message from the buyer's PO public workflow (WLIS_BuyerPOPrivate).
The following figure shows the WLIS_SupplierPOPublic workflow template.
Figure 3-24 WLIS_SupplierPOPublic Workflow Template
The following sections define the key tasks and events at the nodes in the WLIS_SupplierPOPublic workflow template, as shown in the preceding figure:
Supplier PO Private Workflow
The sample application defines the following private workflow templates for the suppliers in the PO process: WLIS_SupplierOnePOPrivate and WLIS_SupplierTwoPOPrivate. The templates are similar.
The following figure shows the WLIS_SupplierOnePOPrivate workflow template.
Figure 3-25 WLIS_SupplierOnePOPrivate Workflow Template
The following sections define the key tasks and events at the nodes in the WLIS_SupplierOnePOPrivate workflow template, shown in the preceding figure:
Application and Data Integration
This section contains the following topics:
Introduction
The workflows for the PO business process and the WLIS_BuyerQPAPrivate workflow integrate the BPM functionality of WebLogic Integration with the application integration and data integration functionality that are also provided by WebLogic Integration.
A buyer-side process uses the application integration framework to update the PO information in the enterprise information system (EIS), based on the PO acknowledgment. It then writes PO acknowledgment information to the POAcknowledgement.xml file.
A supplier-side process uses the data integration framework to translate XML data to binary data, and vice versa.
Application Integration
The WLIS_BuyerQPAPrivate and WLIS_BuyerPOPrivate workflows highlight the application integration functionality provided by WebLogic Integration, and the interaction between workflows and application integration services. (See Buyer QPA Private Workflow and Buyer PO Private Workflow.)
Businesses need enterprise application integration (EAI) solutions that make it possible for applications to share data and business processes without first making changes to their original application code or data structures. WebLogic Integration provides an application integration framework that supports inter-enterprise integration through the use of adapters.
Adapters provide an interface that applications can use to access enterprise data programmatically. For example, an adapter can use a Java class to represent enterprise data, and it can provide methods that applications can invoke to access the data. When an application invokes an access method, the adapter executes the method to retrieve the enterprise data. The application integration functionality provided by WebLogic Integration is based on J2EE Connector Architecture (JCA). In addition to complete compliance with the J2EE standard, the application integration tools available with WebLogic Integration offer other important functionality:
See Introducing Application Integration for details about application integration in the WebLogic Integration environment.
When you define an application view, you create an XML-based interface between WebLogic Integration and an EIS application. In this sample, the EIS system is an RDBMS. The application integration adapter used in the sample is the DBMS adapter that is packaged with the WebLogic Integration product. Based on the DBMS adapter, an application view (WLISAppView.sav) is defined and deployed in WebLogic Integration for this sample. See \samples\wlis\src\examples\wlis\wlai\WLISAppViewDeployer.java in your WebLogic Integration installation.
You can define, test, and deploy an application view using the WebLogic Integration Application View Console, a Web-based user interface. For details about defining application views, see Using Application Integration.
You can also use the Application View Console to view the details of the application view created by the WLISAppviewDeployer.java Java program for this sample, as follows:
The Application View Console is displayed. It displays the Root folder, which contains a list of folders that organize the application views for your enterprise. One of the folders in this window is WLISAppView, the folder that contains the application view for this sample.
Figure 3-26 WebLogic Integration Application View Console
The WLISAppView.sav application view includes the following services and events.
Services |
getContact |
Events |
insertPOEvent |
Click on the following links in the Application View Console to view more information about any service or event:
Data Integration
The WLIS_SupplierOnePOPrivate and WLIS_SupplierTwoPOPrivate workflows highlight the data integration functionality provided by WebLogic Integration. This feature is used to translate data from XML to binary format, and vice versa. For this sample application, the following translations are performed:
Both translations are described in Supplier PO Private Workflow.
The following data integration plug-in actions are available in the Studio to support data integration:
To perform a data translation at a task node in the Studio:
The Binary to XML dialog box is displayed.
The XML to Binary dialog box is displayed.
The following figure shows the Binary to XML dialog box for the final task node (Get PO Ack and transform into XML) in the WLIS_SupplierTwoPOPrivate workflow template, described in Supplier PO Private Workflow.
Figure 3-27 Binary to XML Dialog Box
In the preceding figure note the following:
For this sample application, two translation maps, PO.mfl and POAck.mfl, were built in the Format Builder design tool and saved in the WebLogic Integration repository. The maps, stored in the workflow.jar package, are imported during the setup and configuration of the sample.
You can view the translation maps for this sample by invoking the Format Builder tool, as described in the following section.
Invoke Format Builder
To invoke Format Builder, complete the procedure appropriate for your platform:
Choose Start
a. Open a command window.
b. Go to the bin directory where you installed WebLogic Integration, and execute the fb command. For example, if WebLogic Integration is installed in the default location, enter the following sequence of commands:
cd \bea\wlintegration2.1\bin
fb.cmd
For example, if WebLogic Integration is installed in the default location, enter the following:
cd BEA_Home/wlintegration2.1/bin
Here BEA_Home represents the default directory in which you install BEA products.
. ./fb
View the Sample Translation Maps
You can view the translation maps for this sample as follows:
A dialog box that allows you to browse for files on your system is displayed.
/samples/wlis/lib/xt
See Translating Data with WebLogic Integration for information about using the Format Builder design tool to build and test your translation maps. The following figure shows the PO.mfl translation map being defined in the Format Builder.
Figure 3-28 PO Map in Format Builder
|
Copyright © 2001 BEA Systems, Inc. All rights reserved.
|