9.1 Web Services Infrastructure
Side Note:
Http的语义:GET->Read POST->Update
9.2 Web Service
Web Service 典型的应用场景:旅行代理网站与机票、酒店服务提供商之间的通信。
主要的协议:SOAP和REST
SOAP:
可以通过 https://developers.google.com/appengine/articles/soap 来学习部署一个简单的SOAP Server/Client来获得更多的感性认识。
SOAP消息传输的问题:
WS-ReliableMessaging recommendation.At-least-once: The message is delivered at least once, but an error is reported if it cannot be delivered.At-most-once: The message is delivered at most once, but without any error report if it cannot be delivered.Exactly-once: The message is delivered exactly once, but an error is reported if it cannot be delivered.需要注意与5.3.1的RPC call的语义进行区分。这里的语义只涉及传输。
Pass firewall. Normally firewall allow both HTTP and SMTP messages to pass through.
WS和CORBA的比较
* CORBA is used inside one corporation. WS globally scale
* In general, as mentioned in the previous section, values of types that are remote references (that is, that implement the Remoteinterface) cannot be passed as arguments or returned as results of remote calls.
* Others: Naming/Reference/Ease of use/Efficiency.
总的来讲:Web Service耦合更少,适合global scope的部署,CORBA功能较多,但是更加复杂。
9.3 Service Description
9.4 Directory service.
UDDI
9.7 Web Services的应用
- Service oriented architecture (SOA),基于WS的系统集成。Mashup的兴起。
- The Grid (网格计算)
- 海量数据的分散存贮。分散的服务必须提供接口来查询数据,简单的Http或者Ftp服务因为数据量的问题无法胜任。
- Cloud Computing
- Amazon Web Service (AWS): Compute Cloud, Simple Storage Service, Simple DB, Queue Service, MapReduce, Payment.