definition creates a unique name for a WS-BPEL process definition and associates it with an XML Schema type. The intent is to create a name that has semantic significance beyond the type itself. For example, a sequence number can be an integer, but the integer type does not convey this significance, whereas a named sequence-number property does. Properties can refer to any parts of a variable.
A typical use for a in WS-BPEL is to name a token for correlation of service instances with messages. For example, a social security number might be used to identify an individual taxpayer in a long-running multiparty business process regarding a tax matter. A social security number can appear in many different message types, but in the context of a tax-related process it has a specific significance as a taxpayer ID. Therefore a name is given to this use of the type by defining a , as in the following example:
targetNamespace="http://example.com/properties.wsdl"
xmlns:tns="http://example.com/properties.wsdl"
xmlns:txtyp="http://example.com/taxTypes.xsd"
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
...
In correlation, the property name must have process-wide significance to be of any use. Properties such as price, risk, response latency, and so on, which are used in conditional behavior in a business process, have similar significance. It is likely that they will be mapped to multiple messages, and therefore they need to be named as in the case of correlation properties.
Even in the general case of properties on XML typed WS-BPEL variables the property name should maintain its generic nature. The name is intended to identify a certain kind of value, often with an implied semantic. Any variable on which the property is available is therefore expected to provide a value that meets not just the syntax of the property definition but also its semantics.
The WSDL extensibility mechanism is used to define properties. The target namespace and other useful aspects of WSDL are available to them.
The syntax for a property definition is a new kind of WSDL definition as follows:
...
[SA00019] Either the type or element attributes MUST be present but not both. Properties used in business protocols are typically embedded in application-visible message data.
The notion of aliasing is introduced to map a property to a field in a specific message part or variable value. The property name becomes an alias for the message part and/or location, and can be used as such in expressions and assignments. As an example, consider the following WSDL message definition:
targetNamespace="http://example.com/taxMessages.wsdl"
xmlns:txtyp="http://example.com/taxTypes.xsd"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
element="txtyp:taxPayerInfoElem" />
...
The definition of a property and its location in a particular field of the message are shown in the next WSDL fragment:
targetNamespace="http://example.com/properties.wsdl"
xmlns:tns="http://example.com/properties.wsdl"
xmlns:txtyp="http://example.com/taxTypes.xsd"
xmlns:txmsg="http://example.com/taxMessages.wsdl" ...>
...
messageType="txmsg:taxpayerInfoMsg" part="identification">
txtyp:socialsecnumber
element="txtyp:taxPayerInfoElem">
txtyp:socialsecnumber
The first defines a named property tns:taxpayerNumber as an alias for a location in the identification part of the message type txmsg:taxpayerInfoMsg.
The second provides a second definition for the same named property tns:taxpayerNumber but this time as an alias for a location inside of the element txtyp:taxPayerInfoElem.
The presence of both aliases means that it is possible to retrieve the social security number from both a variable holding a message of messageType txmsg:taxpayerInfo as well as an element defined using txtyp:taxPayerInfoElem.
The syntax for a definition is:
messageType="QName"?
part="NCName"?
type="QName"?
element="QName"?>
?
queryContent
...
The interpretation of the messageType and part attributes, as well as the element is the same as in the corresponding from-spec in copy assignments (see section 8.4. Assignment). The one exception is that the default value of the queryLanguage attribute for the element within a is urn:oasis:names:tc:wsbpel:2.0:sublang:xpath1.0.
[SA00020] A element MUST use one of the three following combinations of attributes:
-
messageType and part,
-
type or
-
element.
If a is defined with the messageType/part combination then the property MUST be available on all WS-BPEL variables where the messageType QName of the variable declaration is identical to that of the . The part attribute and element are applied against the WS-BPEL messageType variable to either set or get the property variable in the same way that the part attribute and element are used in the first from and to specs in assignments.
If a is defined with a type attribute then the property MUST be available on all WS-BPEL variables where the type QName of the variable declaration is identical to that of the . The query is applied against the WS-BPEL variable to either set or get the property variable in the same way that the query is used in the first from and to specs in copy assignments when applied against WS-BPEL variables defined using a type.
If a is defined with an element attribute then the property MUST be available on all WS-BPEL variables where the element QName of the variable declaration is identical to that of the . The query is applied against the WS-BPEL variable to either set or get the property variable in the same way that the query is used in the first from and to specs in copy assignments when applied against WS-BPEL variables defined using an element definition.
Using the same “tns:taxpayerNumber” example from above, for a message variable “myTaxPayerInfoMsg” of messageType txmsg:taxpayerInfoMsg:
and
$myTaxPayerInfoMsg.identification/txtyp:socialsecnumber
have the same output (see section 8.4. Assignment for details).
[SA00022] A WS-BPEL process definition MUST NOT be accepted for processing if it defines two or more property aliases for the same property name and WS-BPEL variable type. For example, it is not legal to define two property aliases for the property tns:taxpayerNumber and the messageType txmsg:taxpayerInfoMsg. The same logic would prohibit having two property aliases on the same element QName and property name value or two property aliases on the same type QName and property name value.
[SA00021] Static analysis MUST detect property usages where property aliases for the associated variable's type are not found in any WSDL definitions directly imported by the WS-BPEL process. As described in 8. Data Handling and 9. Correlation, property usages in WS-BPEL include , getVariableProperty functions as well as assign activity copy and property formats.