Table of Contents

Search

  1. Preface
  2. Part 1: Using Process Developer
  3. Part 2: Creating and Modifying Processes
  4. Part 3: Functions, Events, Errors, and Correlation
  5. Part 4: Testing and Deployment
  6. Part 5: Process Central and Process Server (On-Premises)

Process Developer

Process Developer

Disable bpel:selectionFailure Fault Example

Disable bpel:selectionFailure Fault Example

The following example shows the effect of enabling and disabling the
Disable bpel:selectionFailure Fault
(BPEL4WS 1.1 processes:
bpws:selectionFailure
) option.
For details on WS-BPEL 2.0 processes, see
Using the Process Developer Disable Selection Failure Fault Extension
.
For a description of this BPEL4WS 1.1 preference, see
Simulation Preferences
.
Code sample:
<assign> <copy> <from part="OrderInfo" query="/ns1:OrderInfo /ns1:OrderHeader/ns1:BillToInfo/ns1:Addr1" variable="var1"/> <to part="OrderInfo" query="/ns1::Addr1" variable="var2"/> </copy> </assign>
In the code sample, the
Assign From/To
query is for an optional element, as shown in the schema snippet below.
Schema Snippet for Var1 and Var2
:
<xs:complexType name="AddressInfoType"> <xs:sequence> <xs:element ref="ord:Name"/>
<xs:element ref="ord:Addr1" minOccurs="0"/>
<xs:element ref="ord:Addr2" /> <xs:element ref="ord:City"/> <xs:element ref="ord:St"/> <xs:element ref="ord:Zip"/> <xs:element ref="ord:Cntry" /> </xs:sequence> </xs:complexType> <xs:element name="BillToInfo" type="ord:AddressInfoType"/>
Var1 Sample Data
Var2 Initialization
<ns1:OrderInfo xmlns:ns1="http://temp.com"> <ns1:OrderHeader> <ns1:OrdId>78</ns1:OrdId> <ns1:BillToInfo> <ns1:Name>Name1</ns1:Name>
(Addr1 is missing)
<ns1:Addr2>1 Main St </ns1:Addr2> <ns1:City>Albany</ns1:City> <ns1:St>NY</ns1:St> <ns1:Zip>12012</ns1:Zip> <ns1:Cntry>USA</ns1:Cntry> </ns1:BillToInfo> ...
<ns1:OrderInfo xmlns:ns1="http://temp.com"> <ns1:OrderHeader> <ns1:OrdId/> <ns1:BillToInfo> <ns1:Name/>
<ns1:Addr1/>
<ns1:Addr2/ <ns1:City/> <ns1:St/> <ns1:Zip/> <ns1:Cntry/> </ns1:BillToInfo> ...
With
Disable bpel:selectionFailure Fault
disabled
, the simulation ends in a Selection Failure fault because
Var1
is missing the query selection node, and it cannot be assigned to the
Var2
query selection node.
With
Disable bpel:selectionFailure Fault
enabled, the process terminates normally because the empty selection node is allowed. A null value is added to
Addr1
during the assignment.

0 COMMENTS

We’d like to hear from you!