
比如,在这张图中,使用 .NET技术实现的 payment calculator 是一个外部应用,它发送SOAP消息来初始化合同。进入SOA 服务器后,消息的传播是这样的:
(1)Service Infrastructure 从“绑定组件(在这里是HTTP SOAP Binding)”接收 SOAP消息,并且决定消息的下一个目的地(在这里是BPEL 引擎)。
(2)BPEL 引擎收到消息后,把消息交给 Loan BPEL Process 处理。
(3)Loan BPEL Process 处理完毕后,把返回消息传回给 Service Infrastructure。
(4)Service Infrastructure把返回信息交给下一个目的地(在这里是人工工作流引擎)。
(5)人工工作流引擎把信息交给工单系统,等待经理审批。
......
图的上部虚线框住的部分就是“SOA合成应用”。
1. SOA合成应用的角色构成
(1) Binding Components
建立SOA合成应用与外界的“连接”。分为两种类型:
- Service binding components:SOA合成应用的入口。
- Reference binding components: SOA合成应用的出口。
(2)Service Infrastructure
提供消息的内部传递。
- 接收外部服务提供者的消息(通过SOAP或adapters)。
- 发送消息到服务引擎。
- 接收服务引擎返回的消息,再发送给其它服务引擎或外部服务消费者。
(3)Service Engines 和 Service Components
服务组件运行的容器。每种服务组件都对应其自己的服务引擎。目前,服务组件有以下类型:
- BPEL process
- Business rules
- Human task
- Mediator 在组件之间路由信息。
(4)UDDI 和 MDS
Metadata Service repository 存储所有服务的信息。
(5)SOA Archive
SOA archive (SAR) 是SOA合成应用档案,是发布单元,包括所有服务组件。
(6)Wires
Wires连接不同的组件。连接类型有:
- Services to service components
- Service components to other service components
- Service components to references
参考文献:
1. http://download.oracle.com/docs/cd/E12839_01/integration.1111/e10224/fod_intro1.htm#SOASE9019。




在OrderBooking调用CreditRatingService的Partner关系中,OrderBooking是服务的请求者,CreditRatingService是服务的提供者。因为一个Role最终要对应到WSDL中的一个portType。同步调用使用一个portType就可以拿到结果,因此不需要设置My Role。

在OrderBooking调用RapidDistributors的Partner关系中,OrderBooking是服务的请求者,RapidDistributors是服务的提供者。因为异步调用需要2个Operation才能完成,因此需要设置2个Role(Partner Role 和 My Role),对应2个WSDL中的portType。同步调用使用一个portType就可以拿到结果,因此不需要设置。


