Specify the business logic for the Assign1 element from the BPEL Mapper as follows:
Select the Assign1 element in the BPEL Designer's Design view, and click the Designer's Mapper button to open the BPEL Mapper.
The Assign1 activity is displayed in the BPEL Mapper window.
From the BPEL Mapper, expand the HandlePurchaseOrderIn node in the Output pane, and the IsInventoryAvailableIn nodes in the Input pane.
Map purchaseOrder, under Variables -> HandlePurchaseOrderIn in the Output pane of the BPEL Mapper, to purchaseOrder, under Variables -> IsInventoryAvailableIn in the Input pane of the BPEL Mapper.
Specify the business logic for the If1 element from the BPEL Mapper as follows:
Select the If1 element in the BPEL Designer's Design view, and click the Designer's Mapper button to open the BPEL Mapper.
The If1 activity is displayed in the BPEL Mapper window.
Map InventoryStatus, under Variables -> IsInventoryAvailableOut -> InventoryStatus in the Output pane of the BPEL Mapper, to Boolean Condition under If1 in the Input pane of the BPEL Mapper.
Add an Assign element to the If1 element in the process flow. To do this, drag-and-drop the Assign activity from the BPEL Designer Palette to the link between the beginning and ending node of the If1 element. The Assign2 element is added to the InventoryService process flow.
Specify the business logic for the Assign2 element from the BPEL Mapper as follows:
Select the Assign2 element in the BPEL Designer's Design view, and click the Designer's Mapper button to open the BPEL Mapper.
The Assign2 activity is displayed in the BPEL Mapper window.
Map orderId, under Variables -> HandlePurchaseOrderIn -> purchaseOrder in the Output pane of the BPEL Mapper, to orderId, under Variables -> HandlePurchaseOrderOut -> receipt in the Input pane of the BPEL Mapper.
Map customerId, under Variables -> HandlePurchaseOrderIn -> purchaseOrder in the Output pane of the BPEL Mapper, to customerId, under Variables -> HandlePurchaseOrderOut -> receipt in the Input pane of the BPEL Mapper.
Map orderDescription, under Variables -> HandlePurchaseOrderIn -> purchaseOrder in the Output pane of the BPEL Mapper, to orderDescription, under Variables -> HandlePurchaseOrderOut -> receipt in the Input pane of the BPEL Mapper.
From the BPEL Mapper toolbar's Number menu, select Number Literal and drag Number Literal to the center pane of the Mapper. A Number Literal function box appears in the Mapping pane. Enter 44.59 as the Number Literal value.
Map the outbound 44.59 node of the Number Literal function box, to price, under Variables -> HandlePurchaseOrderOut -> receipt in the right pane of the BPEL Mapper.
Add an Assign element to the Else of the If1 element in the process flow. To do this, drag-and-drop the Assign activity from the BPEL Designer Palette to the center of the Else branch of the If1 element.
The Assign3 element is added to the InventoryService process flow.
Specify the business logic for the Assign3 element from the BPEL Mapper as follows:
Select the Assign3 element in the BPEL Designer's Design view, and click the Designer's Mapper button to open the BPEL Mapper.
The Assign3 activity is displayed in the BPEL Mapper window.
Map orderId, under Variables -> HandlePurchaseOrderIn -> purchaseOrder in the Output pane of the BPEL Mapper, to orderId, under Variables -> HandlePurchaseOrderOut -> receipt in the Input pane of the BPEL Mapper.
Map customerId, under Variables -> HandlePurchaseOrderIn -> purchaseOrder in the Output pane of the BPEL Mapper, to customerId, under Variables -> HandlePurchaseOrderOut -> receipt in the Input pane of the BPEL Mapper.
Map inventoryStatusMessage, under Variables -> IsInventoryAvailableOut -> inventoryStatus in the Output pane of the BPEL Mapper, to orderDescription, under Variables -> HandlePurchaseOrderOut -> receipt in the Input pane of the BPEL Mapper.
Validate your new BPEL process as follows:
From the BPEL Designer's toolbar, click the Validate XML button. Validation of the BPEL process is performed. The results of the validation are displayed in the NetBeans IDE Output window.
If the validation process finds any errors, the Output window lists each error with a link to the point of error in the BPEL Designer. Double-click the hyperlink and refer to the error message for information on how to resolve the error.
Once you have resolved any errors, run validation again to ensure that there are no remaining errors or warnings.
Click Save All to save your changes.