- WS-BPEL 2.0 Beginner's Guide
- Matjaz B. Juric Denis Weerasiri
- 326字
- 2021-08-05 18:01:35
Understanding sequential invocation
Within the <process>
element, a BPEL process will usually have the top-level <sequence>
element. Within the sequence, the process will first wait for the incoming message to start the process. This wait is usually modeled with the <receive>
construct. It could also be modeled with the <pick>
activity, if we expect more than one incoming message. We will explain the <pick>
activity in Chapter 10, Events and Event Handlers.
Then, the process will invoke the related services using the <invoke>
construct. Such invocations can be done sequentially or in parallel. If we want to make them sequential, we simply write an <invoke>
activity for each invocation, and the services will be invoked in that order. Finally, the process will return a response using <reply>
. This is shown in the following code excerpt:
<process ...> ... <sequence> <!-- Wait for the incoming request to start the process --> <receive ... /> <!-- Invoke a set of related services, one by one --> <invoke ... /> <invoke ... /> <invoke ... /> ... <!-- Return the response --> <reply ... /> </sequence> </process>
A closer look at <invoke>
With <invoke>
, the BPEL process invokes operations on other services. We have to specify the following attributes:
partnerLink
: This specifies which partner link will be usedportType
: This specifies the used port typeoperation
: This specifies the name of the operation to invoke (<invoke>
)
When the business process invokes an operation on the service, it sends a set of parameters. These parameters are modeled as input messages with services. To specify the input message for the invocation, we use the inputVariable
attribute and specify a variable of the corresponding type.
If we invoke a synchronous request/response operation, it returns a result. This result is again a message, modeled as an output message. To store it in a variable, <invoke>
provides another attribute, called outputVariable
.
We can also specify a name
attribute. We use the name
attribute to provide names for activities.
The following code excerpt shows an example of the <invoke>
activity. We specify that the BPEL process should invoke the synchronous operation getBookData
on port type ns2:bookstoreABPEL
using the BookstoreABPEL
partner link, providing the input from the BookstoreARequest
variable and storing the output in the BookstoreAResponse
variable, as shown in the following screenshot:

- Microsoft SQL Server企業(yè)級(jí)平臺(tái)管理實(shí)踐
- MongoDB管理與開(kāi)發(fā)精要
- 云計(jì)算服務(wù)保障體系
- OracleDBA實(shí)戰(zhàn)攻略:運(yùn)維管理、診斷優(yōu)化、高可用與最佳實(shí)踐
- 大數(shù)據(jù)技術(shù)入門(mén)
- LabVIEW 完全自學(xué)手冊(cè)
- PostgreSQL指南:內(nèi)幕探索
- 探索新型智庫(kù)發(fā)展之路:藍(lán)迪國(guó)際智庫(kù)報(bào)告·2015(上冊(cè))
- 區(qū)域云計(jì)算和大數(shù)據(jù)產(chǎn)業(yè)發(fā)展:浙江樣板
- 算法設(shè)計(jì)與分析
- Kubernetes快速進(jìn)階與實(shí)戰(zhàn)
- Oracle 內(nèi)核技術(shù)揭密
- 數(shù)據(jù)產(chǎn)品經(jīng)理寶典:大數(shù)據(jù)時(shí)代如何創(chuàng)造卓越產(chǎn)品
- 精通Neo4j
- MySQL核心技術(shù)手冊(cè)