官术网_书友最值得收藏!

Time for action – developing parallel flows

Let's now modify the BookWarehousingBPEL process so that the BookstoreA and BookstoreB services will be invoked in parallel. We should do the following:

  1. To invoke BookstoreA and BookstoreB services in parallel, we need to add the Flow structured activity to the process flow just before the first invocation, as shown in the following screenshot:
  2. We can see that two parallel branches have been created. We simply drag-and-drop both the invoke activities into the parallel branches:

That's all! We can create more parallel branches if we need to by clicking on the Add Sequence icon.

What just happened?

We have modified the BookWarehousingBPEL process so that the BookstoreA and BookstoreB <invoke> activities are executed in parallel. A corresponding <flow>activity has been created in the BPEL source code. Within the <flow> activity, both <invoke> activities are nested. Please notice that each <invoke> activity is placed within its own <sequence> activity. This would make sense if we would require more than one activity in each parallel branch. The BPEL source code looks like the one shown in the following screenshot:

Deploying and testing the parallel invocation

We will deploy the project to the SOA Suite process server the same way we did in the previous sample. Then, we will log in to the Enterprise Manager console, select the project Bookstore, and click on the Test Web Service button.

To observe that the services have been invoked in parallel, we can launch the flow trace (click on the Launch Flow Trace button) in the Enterprise Manager console, click on the book warehousing BPEL processes and activate the flow view, which shows that both bookstore services have been invoked in parallel.

主站蜘蛛池模板: 文水县| 武冈市| 内江市| 高密市| 共和县| 枣强县| 贞丰县| 南宁市| 靖宇县| 秦安县| 青河县| 离岛区| 鹰潭市| 兴和县| 枣强县| 阿拉善左旗| 怀仁县| 岚皋县| 洛宁县| 彰武县| 台湾省| 广安市| 吉隆县| 岐山县| 米林县| 石林| 申扎县| 瑞昌市| 临桂县| 平顶山市| 满城县| 丹东市| 鄂托克旗| 扶风县| 普定县| 武安市| 永定县| 宜都市| 丰宁| 射阳县| 临漳县|