分布式应用学习笔记(2)
6.1.4 WSDD ..................................................................................................................................................... 37
6.2 AXIS ............................................................................................................................................................. 38
6.2.1 Axis基本概念 ...................................................................................................................................... 38
6.2.2 Axis的安装 ........................................................................................................................................... 38
6.2.3 Axis的配置 ........................................................................................................................................... 38
6.2.4 Axis的测试 ........................................................................................................................................... 39
6.2.5 服务的发布 ........................................................................................................................................... 39
6.2.6 服务的访问 ........................................................................................................................................... 46
6.2.7 客户端编程 ........................................................................................................................................... 47
6.2.8 服务类型 ................................................................................................................................................ 49
6.2.9 SOAP信封 ............................................................................................................................................ 51
MOM JMS 分布式 架构
1 通信基础知识
1.1 Synchronous communication
Synchronous communication represents a tight coupling between a sender and receiver:
1. the sender and receiver must both be available - i.e. real-time communication.
2. the sender will block until the response is available.
3. communication is one-to-one.
4. sender / receiver have some knowledge of each other - e.g. location, protocol,
methods, etc.
5. the sender is responsible for dealing with failures - e.g. retries, etc.
“request/response” is an example of a synchronous communication paradigm.
Example : a browser sends a request to a web server and waits for the response. The
wait can indefinite or until a timeout occurs.
1.2 Asynchronous communication
Asynchronous communication represents a loose coupling between senders / receivers :
1. sender and receiver communicate via a midde-man / broker / mediator.
2. no requirement for sender or receiver to both be available - i.e. deferred
communication.
3. sender doesn t wait for a response (if any).
4. communication can be one-to-one or one-to-many.
5. sender and receiver have no direct knowledge of each other so promotes reuse /
extension - e.g. new senders / receivers can be added without impact; senders /
receivers can be replaced as required.
6. the broker is responsible for dealing with failures - e.g. retries, etc.
7. messages may be delayed and/or arrive out of sequence.
“queues” and “publisher/subscriber” are examples of asynchronous communication
paradigm.
Example : the sender mail client sends an email via a mail server. The sender mail
server attempts delivery to the recipient mail server and repeats if unsuccessful. The
recipient mail client picks up the mail from the recipient server next time they re online.
1.3 Benefits of synchronous and asynchronous communication
Synchronous communication(e.g. RMI):
1. real-time response.
2. lock-step - order of execution guarantee.
MOM JMS 分布式 架构
3. self-contained – it s a single-shot “transaction”, no ongoing management over time
so suitable in pooled environments like EJB.
Asynchronous communication(e.g. JMS):
1. loose coupling.
2. producers/consumers delegate responsibility of reliable message delivery to MOM.
3. deferred communication - consumers can be offline, servers down, etc.
4. promotes reuse - components can be added/removed/modified without impact.
5. supports broadcast of messages.
MOM JMS 分布式 架构
2 Java远程通信技术
2.1 基本原理
要实现网络机器间的通讯,首先得来看看计算机系统网络通信的基本原理,在底层
层面去看,网络通信需要做的就是将流从一台计算机传输到另外一台计算机,基于传
输协议和网络IO来实现,其中传输协议比较出名的有 http、tcp、udp等等,http、tcp、
udp都是在基于Socket概念上为某类应用场景而扩展出的传输协议,网络IO,主要有
bio、 nio、aio三种方式,所有的分布式应用通讯都基于这个原理而实现,只是为了应
用的易用,各种语言通常都会提供一些更为贴近应用易用的应用层协议。
2.2 应用级远程通信协议
远程服务通讯,需要达到的目标是在一台计算机发起请求,另外一台机器在接收
到请求后进行相应的处理并将结果返回给请求端,这其中又会有诸如one way request、
同步请求、异步请求等等请求方式,按照网络通信原理,需要实现这个需要做的就是
将请求转换成流,通过传输协议传输至远端,远端计算机在接收到请求的流后进行处
理,处理完毕后将结果转化为流,并通过传输协议返回给调用端。
原理是这样的,但为了应用的方便,业界推出了很多基于此原理之上的应用级的
协议,使得大家可以不用去直接操作这么底层的东西,通常应用级的远程通信协议会
提供:
1. 为了避免直接做流操作这么麻烦,提供一种更加易用或贴合语言的标准传输格
式;
2. 网络通信机制的实现,就是替你完成了将传输格式转化为流,通过某种传输协
议传输至远端计算机,远端计算机在接收到流后转化为传输格式,并进行存储
或以某种方式通知远端计算机。
所以在学习应用级的远程通信协议 …… 此处隐藏:4295字,全部文档内容请下载后查看。喜欢就下载吧 ……
相关推荐:
- [高中教育]电子线路高频非线性部分2.1
- [高中教育]中班美术活动——我的小手
- [高中教育]常用三极管参数大全
- [高中教育]计算机常见故障及解决办法
- [高中教育]风机基础环水平度控制方法探讨
- [高中教育]机械安全工程(专升本)阶段性作业3
- [高中教育]2009年安徽省高考语文考试说明刍议
- [高中教育]unit5 let's eat公开课教案设
- [高中教育]计算机网络原理课后习题答案
- [高中教育]2016-2022年中国新能源市场研究与投资
- [高中教育]2015-2020年中国会议行业市场评估及投
- [高中教育]经销商大会峰会主持人串词开场白
- [高中教育]2014新版北师大数学三年级上册小熊购物
- [高中教育]七年级第一学期体育与健康全套教案
- [高中教育]第三章:国际金融市场
- [高中教育]六年级下册数学单元测试-2.比例 北师大
- [高中教育]2016年上海海事大学法学院624刑法之《
- [高中教育]中国碳化钙产业竞争现状及未来五年投资
- [高中教育]网络时代,我们怎么玩
- [高中教育]圆锥曲线——高中数学基础知识与典型例
- 高集医院世界艾滋病宣传日活动方案
- 苏教版六年级英语上册期末试卷含答案
- 全民枪战生化英雄模式幽灵怎么玩 生化
- 灿烂的宋元文化一导学案
- 第2章货币资金与应收款项
- 北师大版八年级下册数学第三章《分式》
- 浅析高分子材料成型加工技术
- 华南理工大学2013年度共青团先进集体及
- 教师资格科目二小学教案模板(共合集)
- 工程扩建可研报告
- 中华人民共和国海事局2014年度招录公务
- 提高农村小学生作文能力的教学尝试
- 徒手心肺复苏术操作步骤
- 毛概试题库7-15章
- 2014-2015学年度(上)初中班主任工作计
- 企业驾驶员安全生产责任书
- 第07章 不等式测试题-2016年高考文科数
- 医疗器械经营企业工作程序
- 考研英语必背36篇_彩版_精华
- 初中9月13-15假期作业 (1)




