| Oracle® Application Server Adapter for PeopleSoft User's Guide 10g Release 3 (10.1.3.4.0) Part Number E14198-01 |
|
|
View PDF |
OracleAS Adapter for PeopleSoft integrates seamlessly with Oracle Business Process Execution Language (BPEL) Process Manager to facilitate Web service integration. Oracle BPEL Process Manager is based on the Service-Oriented Architecture (SOA). It consumes adapter services exposed as Web Service Definition Language (WSDL) documents.
This chapter includes the following topics:
Overview of Adapter Integration with Oracle BPEL Process Manager
Invoking Adapter Request-Response Service from Oracle BPEL Process Manager
To integrate with Oracle BPEL Process Manager, OracleAS Adapter for PeopleSoft must be deployed in the same OC4J container as Oracle BPEL Process Manager. The underlying adapter services must be exposed as WSDL files, which are generated during design time in Oracle Application Server Adapter Application Explorer (Application Explorer) for both request-response (outbound) and event notification (inbound) services of the adapter. See "Generating WSDL (J2CA Configurations Only)" for more information.
The generated WSDL files are used to design the appropriate BPEL processes for inbound or outbound adapter services. A completed BPEL process must be successfully compiled in JDeveloper and deployed to a BPEL server. Upon deployment to the BPEL server, every newly built process is automatically deployed to the Oracle BPEL Console, where you run, monitor, and administer BPEL processes, and listen to adapter events.
When using the adapter with Oracle BPEL Process Manager, the BPEL PM home directory is OC4J_BPEL, and is located as follows:
OracleAS_home\j2ee\OC4J_SOA
See Also:
Oracle Application Server Adapter Concepts
Oracle BPEL Process Manager Developer's Guide
During installation, OracleAS Adapter for PeopleSoft is deployed as a J2CA 1.0 resource adapter within the OC4J J2CA container. The adapter must be deployed in the same OC4J container as Oracle BPEL Process Manager.
See Also:
Oracle Application Server Adapter ConceptsThe following tools are required to complete your adapter design-time configuration:
OracleAS Adapter Application Explorer (Application Explorer)
Oracle JDeveloper BPEL Designer (JDeveloper) or Eclipse
Note:
The examples in this chapter demonstrate the use of JDeveloper.Before you design a BPEL process, you must create a schema and generate the respective WSDL file using Application Explorer. See "Generating WSDL (J2CA Configurations Only)" for more information.
The purpose of an XML namespace is to allow the deployment of XML vocabularies (where element and attribute names are defined) in a global environment and to reduce the risk of name collisions in a given document when vocabularies are combined. Qualified namespaces are used for stricter schema validation. In documents conforming to this specification, element and attribute names appear as qualified names. Syntactically, they are either prefixed names or unprefixed names. An attribute-based declaration syntax is provided to bind prefixes to namespace names and to bind a default namespace that applies to unprefixed element names. These declarations are scoped by the elements on which they appear so that different bindings may apply in different parts of a document. Processors conforming to this specification must recognize and act on these declarations and prefixes.
In the 10.1.3.1.0 SOA release, the recommendations for BPEL integrations is to perform stricter name space validations. As a result, Application Explorer generates Web services for the back-end with the namespace marked as “Qualified”. During testing or usage phases of this service by BPEL, the request XML document that is used should adhere to the schema and WSDL document. Once again, it is important to remember that the namespaces are qualified. To further understand this point, the difference is illustrated with the following example:
Input XML for BPEL based on unqualified namespaces:
<?xml version="1.0" encoding="UTF-8"?><PS8> <component perform="browse">LOCATION</component> <key name="Setid">SHARE</key> <key name="Location">ALBERTA</key> </PS8>
Input XML for BPEL based on qualified namespaces:
<PS8 xmlns="urn:iwaysoftware:adapter:peoplesoft:ci"> <component perform="find">LOCATION</component> <key name="Setid">SHARE</key> <key name="Location">ALBERTA</key></PS8>
Note: If you are passing an unqualified input against a WSDL document that is expecting qualified namespaces, BPEL will throw the exception as “Unable to process input xml...."
An outbound BPEL process consists of PartnerLink, Invoke, and Assign process activities. You must first create a new Application Server connection, Integration Server connection, and a synchronous BPEL process template.
Create a New Application Server Connection
To create a new Application Server connection:
Display the connections by clicking the Connections Navigator tab at the top of the upper left pane in JDeveloper.

Right-click Application Server and select New Application Server Connection.
The Create Application Server Connection - Welcome dialog box is displayed.
Click Next.
The Create Application Server Connection - Step 1 of 4: Type dialog box is displayed.

Specify a unique name and select a connection type for your Application Server connection and click Next.
The Create Application Server Connection - Step 2 of 4: Authentication dialog box is displayed.

Specify a valid user name and password for the Application Server you want to connect to.
Select Deploy Password.
Click Next.
The Create Application Server Connection - Step 3 of 4: Connection dialog box is displayed.

Select the Single Instance connection option.
Enter localhost as the host name and 6003 for the OPMN port.
Enter home as the OC4J instance name
Click Next.
The Create Application Server Connection - Step 4 of 4: Test dialog box is displayed

Click Test Connection.
When the test is complete and the connection is successful, a Success! message appears in the status area.
Click Finish.
Your newly created Application Server connection is displayed in the Connections Navigator tab under the Application Server node.

Create a New Integration Server Connection
To create a new Integration Server connection:
Display the connections by clicking the Connections Navigator tab at the top of the upper left pane in JDeveloper.

Right-click Integration Server and select New Integration Server Connection.
The Create Integration Server Connection - Welcome dialog box is displayed.
Click Next.
The Create Integration Server Connection - Step 1 of 3: Name dialog box is displayed.

Specify a unique name and click Next.
The Create Integration Server Connection - Step 2 of 3: Connection dialog box is displayed.

Select an Application Server connection, which is already created.
Enter localhost as the host name and 8888 for the port number.
Select Add host name to the list of proxy exceptions and click Next.
The Create Integration Server Connection - Step 3 of 3: Test Connection dialog box is displayed.

Click Test Connection.
When the test is complete and the connection is successful, a Success! message appears in the status area.
Click Finish.
Your newly created Integration Server connection is displayed in the Connections Navigator tab under the Integration Server node.

Testing Outbound BPEL and ESB Processes
The BPEL console enables the testing of deployed BPEL processes. Once a process is deployed, you can manage, monitor, and run an end-to-end scenario using the Initiate tab in the console. The OracleAS Adapter for PeopleSoft is certified for testing using the XML Payload option and the option of running using Through Java Delivery API. It is recommended that developers use this method for testing the OracleAS Adapter for PeopleSoft.
When testing an outbound BPEL process from the BPEL console or an outbound ESB process from the Enterprise Manager console, do not use the XML envelopes that are generated by these consoles. Instead, remove them and use the XML payloads that are generated from the schemas, which conform to the WSDLs for namespace qualifications.
The ESB data flows can be tested using the Enterprise Manager console. When creating an ESB data flow and interactions, the Web services are created and registered with the Oracle Application Server. For more information on creating an ESB outbound process, see Chapter 5, "ESB Integration Examples".
This topic illustrates PeopleSoft service integration. Design-time and run-time configuration is described.
Before you design a process for PeopleSoft service integration, you must generate its respective WSDL file using Application Explorer.
Generating WSDL for a Request-Response J2CA Service
To generate WSDL for outbound interaction in Application Explorer:
Start Application Explorer and connect to a defined PeopleSoft target or create a new target.
See "Defining a Target to PeopleSoft" for more information.
Expand the PeopleSoft target to which you are connected.
Expand Component Interfaces and select LOCATION.
Right-click LOCATION.
The following menu is displayed:

Click Create Outbound JCA Service (Request/Response).
The Export WSDL dialog box is displayed.

Click OK.
You are ready to design a BPEL process in JDeveloper.
Creating a BPEL PM Server Connection
Before you design an outbound BPEL process, you must configure a new Application Server and Integration Server connection in Oracle JDeveloper. For more information, see Chapter 4, "Integration with Oracle BPEL Process Manager".
Creating a BPEL Project for a Synchronous BPEL Process
To create a BPEL Project for a synchronous BPEL process:
At the top of the upper left pane, click the Applications Navigator tab and select an application. If an application does not exist, then you must create an application.

Right-click the application and select New Project.
The New Gallery window is displayed.

From the Items list, select BPEL Process Project and click OK.
The BPEL Process Project dialog box is displayed.

Perform the following steps:
Specify a name for the BPEL process.
The Namespace field is updated automatically.
From the Template list, select Synchronous BPEL Process.
Click OK.
Designing the BPEL Process for the LOCATION Outbound Service
From the Services pane on the right, drag and drop a PartnerLink to the visual editor.
The Create Partner Link dialog box is displayed.

Click the Service Explorer icon (second icon from the left preceding the WSDL File field).
The Service Explorer dialog box is displayed.

Expand your new connection under Adapter Services, followed by adapters, and then applications.
The WSDL tree displayed in the Service Explorer dialog box lists any WSDL files you have created using Application Explorer. The WSDL tree is generated by a WSDL servlet, which is automatically deployed as part of the BPEL Server installation.

Select LOCATION_invoke.wsdl and click OK.
The WSDL File field in the Create Partner Link dialog box displays the name and location of the selected WSDL file. The Partner Link Type field specifies the PartnerLink defined in the WSDL file.

Perform the following steps:
Leave the My Role field unspecified. The role of the PartnerLink is null, as it will be synchronously invoked from the BPEL process.
From the Partner Role list, select the default value LOCATIONRole. This is the role of the BPEL process.
Click OK.
Select Save from the File menu.
From the Process Activities pane on the right, drag an Invoke activity to the visual editor and place it between the Receive activity (receiveInput) and the Reply activity (replyOutput).
The Invoke process activity is shown in the following diagram view.

Drag the blue arrow from Invoke_1 and connect it to the PeopleSoft PartnerLink.
The Edit Invoke dialog box is displayed.

Perform the following steps:
Click the first icon to the right of the Input Variable field, then click OK in the Create Variable window that is displayed.
Repeat the previous step to create a default variable for Output Variable.
Click OK.
Drag an Assign process activity and drop it between receiveInput and Invoke_1.
The following image shows the new Assign activity in JDeveloper visual editor.

Double-click the Assign activity icon.
The Assign dialog box is displayed.

In the Copy Operation tab, click Create and select Copy Operation.
The Create Copy Operation dialog box is displayed. Perform the following steps:
In the From pane, expand Variables, then inputVariable, and then highlight payload.
In the To pane, expand Variables, then Invoke_1_LOCATION_InputVariable, and then highlight input_LOCATION.
Your Create Copy Operation dialog box should look as follows:

To close the Create Copy Operation dialog box and the Assign dialog box, click OK.
From the Process Activities pane on the right, drag another Assign activity to the visual editor and place it between the Invoke activity (Invoke_1) and the Reply activity (replyOutput).
Double-click the Assign activity icon and click Create.
In the Create Copy Operation dialog box, map Invoke_1_LOCATION_OutputVariable, output_LOCATION to outputVariable, payload.
Verify that you have mapped all variables as follows:

Click OK, then click OK again.
Select Save from the File menu.
You have completed the design of your BPEL process.
Deploying the BPEL Process for the LOCATION Outbound Service
JDeveloper deploys the outbound BPEL process directly to Oracle BPEL Console.
To deploy your BPEL process in JDeveloper:
Select Deploy, then Your BPEL PM Server connection, and then Deploy to default domain.
The deployment process starts automatically.
Observe the Messages log at the bottom of the window.
The Messages log displays the deployment status. In this example, it shows a successful deployment message for the process.

If deployment was not successful, click the Compiler tab to view all error and warning messages generated during the deployment process.
The OracleAS Adapter for PeopleSoft request-response service is used to create, delete, update, query back-end data, and to call back-end workflows and transactions. The following section describes how to invoke the adapter synchronous request-response service, also referred to as Outbound Interaction, and how to manage the process in Oracle BPEL Console.
Manage the Deployed Outbound Process in Oracle BPEL Console
JDeveloper deploys the developed process directly to the Oracle BPEL Console, which enables you to run, monitor, and administer BPEL processes.
To invoke adapter request-response service:
Start the Oracle BPEL Console by entering the following URL in a browser:
http://host:port/BPELConsole
Select a domain and provide a valid password.
The Oracle BPEL Console main page is displayed. All deployed BPEL processes are listed in the Dashboard tab.

This tab provides a more detailed view of each deployed process.

Click the PeopleSoft process link, PSFT_outbound_location_invoke (v. 1.0).
The Manage window provides options for managing this BPEL process. Do not change any of the following default settings.

Click the Initiate tab.
The Initiate tab enables you to test your BPEL process.

Perform the following steps:
From the Initiating a test instance list, select XML Source.
Select the Java through delivery API link in the right side of the test area.
Enter the following code in the text area provided for XML input:
<?xml version="1.0" encoding="UTF-8"?> <PS8 SERVICENAME="LOCATION" METHODNAME="LOCATION" LICENSE="test"> <component perform="browse">LOCATION</component> <key name="SETID">SHARE</key> <key name="LOCATION">ALBERTA</key></PS8>
Click Post XML Message.
The response received from the PeopleSoft system is displayed in the Initiate window.
See Also:
Oracle Application Server Adapter ConceptsThis topic illustrates PeopleSoft event integration. Design-time and run-time configuration is described.
You must create a separate channel for every event and select that channel when you generate WSDL for inbound interaction using Application Explorer.
Note:
If two or more events share the same channel, event messages may not be delivered to the right BPEL process.Creating a Channel
To create a channel:
Click the Events node.
Expand the PeopleSoft node.
The ports and channels nodes appear in the left pane.

Right-click Channels and select Add Channel.
The Add Channel dialog box is displayed.

Provide the following information:
Enter a name for the channel, for example, PSFT_Channel.
Enter a brief description (optional).
From the Protocol list, select HTTP Listener.
Click Next.
When the Basic dialog box is displayed, enter the system information as specified in the following table:
| Parameter | Description |
|---|---|
| Listener port | Port on which to listen for PeopleSoft event data. |
| Https | For a secure HTTP connection, select the Https check box. |
| Synchronization Type | Choose from the following synchronization options:
Important: The PeopleSoft channel will not work if the synchronization type is set to REQUEST. |
Click OK.
The channel appears under the channels node in the left pane. An X over the icon indicates that the channel is currently disconnected.
Generating WSDL for Event Notification
After you create a channel and verify that it is not started, you must generate WSDL for the event using Application Explorer.
Start Application Explorer.
Expand PeopleSoft.
Click a target name under the PeopleSoft node, for example, PSFTtarget.
Verify your connection parameters and provide the required password.
Right-click the target name and select Connect.
The x icon disappears, indicating that the target is connected.

Expand Messages and select LOCATION_SYNC.VERSION_1.
Right-click LOCATION_SYNC.VERSION_1.

Select Create Inbound JCA Service (Event).
The Export WSDL dialog box is displayed.

Perform the following steps:
In the Name field, specify the name of the WSDL file.
Ensure that qualified is selected as the element form, which is the default.
From the Channel drop-down list, select the channel you created for this inbound service.
Important: You must create a separate channel for every event. Verify that the channel is stopped before run-time.
Creating a BPEL PM Server Connection
Before you design a BPEL process using the WSDL you generated in Application Explorer, you must configure a new Application Server and Integration Server connection in Oracle JDeveloper. For more information, see Chapter 4, "Integration with Oracle BPEL Process Manager".
Designing the BPEL Process for the LOCATION_SYNC.VERSION_1 Inbound Service
To design a BPEL process for inbound interaction:
At the top of the upper left pane, click the Applications Navigator tab and select an application.

Right-click the application and select New Project.
The New Gallery dialog box is displayed.

From the Items list, select BPEL Process Project and click OK.
The BPEL Process Project dialog box is displayed.

Perform the following steps:
Specify a name for the project, for example, PSoftTLOCATION_inbound.
The Namespace field is updated automatically.
From the Template list, select Empty BPEL Process.
Click OK.
From the Services pane on the right, drag and drop a PartnerLink to the visual editor.
The Create Partner Link dialog box is displayed.

Click the Service Explorer icon (second icon from the left preceding the WSDL File field).
The Service Explorer dialog box is displayed.

Expand your new connection, then expand adapters, and then applications.
The WSDL tree displays the WSDL files you created using Application Explorer. The WSDL tree is generated by a WSDL servlet, which is automatically deployed as part of the BPEL Server installation.

Select LOCATION_SYNC.VERSION_1_receive.wsdl and click OK.
The Create Partner Link dialog box is displayed.

The WSDL File field displays the name and location of the selected WSDL file. The Partner Link Type field specifies the PartnerLink defined in the WSDL file.
Perform the following steps:
From the My Role list, select the default value LOCATION_SYNC.VERSION_1Role.
Leave the Partner Role field unspecified.
Click Apply, and then OK.
The new PSFT_PL1 PartnerLink appears in the visual editor.

From the Process Activities pane on the right, drag a Receive activity to the visual editor and place it in the designated placeholder labeled Drop Activity Here.
Connect the Receive activity to the PSoft_PL1 PartnerLink.
The Edit Receive dialog box is displayed.

Perform the following steps:
Specify a name for the Receive Activity, for example, Receive_LOCATION.
Click the first icon to the right of the Variable field, then click OK in the Create Variable dialog box that is displayed.
Verify that the Create Instance check box is selected.
Click Apply.
The Receive dialog box should no longer display any warnings or errors.
Click OK.
Select Save from the File menu.
Deploying the BPEL Process for the LOCATION_SYNC.VERSION_1 Inbound Service
The following topics describe how to trigger an event in PeopleSoft and verify event integration using OracleAS Adapter for PeopleSoft.
Triggering an Event in PeopleSoft to Test Event Runtime Integration
To trigger an event in PeopleSoft:
Log in to PeopleSoft, select PeopleTools, Integration Broker, and then Node Definitions.

Enter the node name you will be using, for example, EXTERNAL; then click Search.

Click the Connectors tab.

Enter HTTPTARGET in the Connector ID field; then enter the listener URL and its port in the PRIMARYURL field.
To save the configuration, click Save.

From Menu in the left pane, select Set Up Financials/Supply Chain, Common Definitions, Location, and then Location.

To find the location record you want to update, click Search; then make the changes and click Save.
When the change is saved, it triggers an event and sends the event to the listener.
Verifying the Results
To verify your results:
Log in to Oracle BPEL Console at
http://host:port/BPELConsole
Provide a valid user name and password.
Click the Instances tab.
Recently received run-time events are displayed in the Instances tab.

Click an instance, then click Audit to see the received event message.