How To Use RPC-Style Files

6-54 Oracle Fusion Middleware Developers Guide for Oracle SOA Suite part=header1 use=literal soap:header message=tns:CustomHeaderMessage part=header2 use=literal soap:body use=literal input operation binding 2. Create a BPEL source file that declares the header message variables and uses bpelx:headerVariable to receive the headers, as shown in Example 6–106 . Example 6–106 bpelx:headerVariable Use variables variable name=input messageType=tns:HeaderServiceRequestMessage variable name=event messageType=tns:HeaderServiceEventMessage variable name=output messageType=tns:HeaderServiceResultMessage variable name=customHeader messageType=tns:CustomHeaderMessage variables sequence -- receive input from requester -- receive name=receiveInput partnerLink=client portType=tns:HeaderService operation=initiate variable=input bpelx:headerVariable=customHeader createInstance=yes

6.22.2 How to Send SOAP Headers in BPEL

This section provides an example of how to send SOAP headers. To send SOAP headers in BPEL: 1. Define an SCA reference in the composite.xml to refer to the HeaderService. 2. Define the custom header variable, manipulate it, and send it using bpelx:inputHeaderVariable, as shown in Example 6–107 . Example 6–107 bpelx:inputHeaderVariable Use variables variable name=input messageType=tns:HeaderTestRequestMessage variable name=output messageType=tns:HeaderTestResultMessage variable name=request messageType=services:HeaderServiceRequestMessage variable name=response messageType=services:HeaderServiceResultMessage variable name=customHeadermessageType=services:CustomHeaderMessage variables ... -- initiate the remote process -- invoke name=invokeAsyncService partnerLink=HeaderService portType=services:HeaderService bpelx:inputHeaderVariable=customHeader operation=initiate inputVariable=request Manipulating XML Data in a BPEL Process 6-55

6.23 Declaring Extension Namespaces in BPEL 2.0

You can extend a version 2.0 BPEL process to add custom extension namespace declarations. With the mustUnderstand attribute, you can indicate whether the custom namespaces carry semantics that must be understood by the BPEL process. If a BPEL process does not support one or more of the extensions with mustUnderstand set to yes, the process definition is rejected. Extensions are defined in the extensions element. Example 6–108 provides details. Example 6–108 Extension Namespace Declaration Syntax process ... ... extensions? extension namespace=myURI mustUnderstand=yes|no + extensions ... process The contents of an extension element must be a single element qualified with a namespace different from the standard BPEL namespace. For more information about extension declarations, see the Web Services Business Process Execution Language Version 2.0 Specification located at the following URL: http:www.oasis-open.org

6.23.1 How to Declare Extension Namespaces

To declare extension namespaces: 1. In a BPEL 2.0 process, click the Extensions icon above Oracle BPEL Designer. The Extensions dialog is displayed.

2. Select the Extensions folder, then click the Add icon.

The Extension dialog is displayed.

3. In the Namespace field, enter the extension namespace to declare. This namespace

must be different from the standard BPEL namespace.

4. If you want the extensions to be recognized by the BPEL process, select the Must

Understand checkbox.

5. Click OK.

6. Click Close.

6.23.2 What Happens When You Create an Extension

After you complete your design, the .bpel process looks as shown in Example 6–109 . Example 6–109 Extension with Custom Namespace extensions extension namespace=http:xmlns.mycompany.commyNamespace mustUnderstand=yes extensions