下载本文档
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
1、想搞清楚remotepublish可以看看这篇文章(考验英语水平的时间到了 don't rely on remotepublish() by bondolo on apr 20, 2007 sie it's earliest versions the jxta jse api has includ remotepublish() as part of the discovery api. this is unfortunate because remotepublish() is frequently misu and it's not really that usef
2、ul to begin with. some jxta users assume that advertisements must be remote published to another peer in order for the advertisement to be discovered. this is not true! un the advertisement needs to discoverable while the peer is unreachable or offline then local publiion is almost always sufficient
3、. part of the confusion is undoubtably e to the presence of two methods, publish() and remotepublish(). in the jxta jse and jxta-c apis remotepublish() and publish() are separate apis for implementation efficiency reasons only. you should conser advertisement publication as only one concept-the publ
4、ish operation with an option for remote republication. remote publication is intended to be only a means for easily requesting remote republication. in every case where remotepublish() is used it should be accompanied by appropriate local publication. what remotepublish() does : send the provided ad
5、vertisement to remote peers may republish the advertisement locally. there a couple of big question marks that should arise from this ement. what is gained by having the other peers republish one of my advertisements?which other peers will be receiving the advertisement?will the peers receive the ad
6、vertisement accept my request and actually publish my advertisement? let's delve into these questions a little further. peers publish advertisements to allow other peers to discover their resources. noally the advertisements published by a peer refer either directly or indirectly to that peer. d
7、irect references to the publishing peer most commonly are it's peerid but can ao include the peer's name or other application specificidentifiers. indirect references include the pipeids for pipes the peer is listening on or references to other advertisements that the peer has also published
8、. even indirect references include descriptions of services that the publishing peer might be running. for advertisements with direct references it is certainly best if the publishing peer itself is the responder when queries are made for the advertisement. not only does this ensure that the queryin
9、g peer receives the most recent version of the advertisement it also ensures that the querying peer receives only active advertisements. for queries which return multiple results having only the original publisher respond can also improve the relevance of responses since responses will be generated
10、only by (and referring to) active peers. for advertisements with indirect peer references it's less important that the originating peer be the peer that responds to queries for the advertisement, but the same advantages that apply for advertisements with direct references may still apply. this i
11、s particularly true for pipe advertisements. the peers which respond should be the peers which are listening on the pipe. in cases where the same advertisement applies to many peers, as is common for pipe advertisements, as long as one of the publishers responds then the query will be satisfied. so
12、what's gained by having your advertisement republished via remotepublish() by other peers and when is it useful? remote republication does provide an aitional (an usually unnecessary) source for your advertisement. it also may make your peer's advertisement available when your peer is not av
13、ailable. this may or may not be a benefit as it could result in other peers wasting trying to contact your peer when it is unreachable. once you've decided that you want your advertisement republished by other peers you are still faced with two additional questions, "which peers can i ask t
14、o republish my advertisement and will they do so?" there are no simple answers to these questions and the answers are not consistent. these questions are icult to answer for many reasons not limited to; varying network topologies, varying network policies and peer autonomy. remotepublish() is a
15、 request you make to other peers on the network. there is no way to force the other peers to accept your request nor is there guaran that any other peers are even listening. in remotepublish()'s default form no particular peer is asked to perform the republication, any peer receiving the message
16、 is requested to republish the advertisement. even when you designate a specific peer with remotepublish() it is not required to accept your advertisement. a peer may choose to ignore your request due to space limitations, a configured policy or any other reason and it will not inform your peer of i
17、t's refusal. assuming another peer does choose to accept your remotepublish() republication request the peer may not retain the advertisement for the entire time you requested. peers often place tight limits on the total number of advertisements they are willing to republish or on the expiration
18、 time of advertisements received through remotepublish(). you may be wondering if there is any special interaction between remotepublish() and the rendezvous service. while it is true that in most network configurations a rendezvous peer is likely to receive all remotepublish() requests from it'
19、s client peers, rendezvous server peers do not offer any special republication privileges to their clients. all of the preceding restrictions still apply. in particular, the restrictions on advertisement expiration were added to jxta implementations specifically to prevent rendezvous server peers fr
20、om being flooded with long-lived bogus advertisements. here's a test we've made since 2002: "does your application still work without remote publication?" since even before jxta jse 2.0 we've considered making remote publish a "no-op" for some configurations, particul
21、arly ad hoc and relayed configurations. in ad hoc the remote republications all end up as very noisy and generally pointless multicast traffic. for relayed configurations removing remotepublish() would slightly reduce relay load. since remotepublish() is occasionally useful and can sometimes slightly improve performance by reducing the number of hops a query must travel we've so far left it d. a properly written jxta applicati
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 中华民族的抗日战争和人民解放战争单元检测 2024-2025学年高一历史统编版(2019)必修中外历史纲要上
- 2024届宁夏银川市唐徕中学高三下学期适应性考试语文试题(解析版)
- 充电桩车棚施工方案及充电桩防汛
- 大学生心中红色经典电影的调查
- 股权激励对公司股东价值创造的影响
- 股权融资对企业社会责任评价的提升影响研究分析
- 江苏省南京师大附中2024年中考数学最后一模试卷含解析
- 娱乐保险行业市场发展趋势及投资咨询报告
- 2023年云南省红河州同舟社会工作服务中心招聘笔试真题
- 2023年昆明市机关幼儿园教育集团教师招聘笔试真题
- 食堂设备参数及清单
- 七年级上学期家长会课件
- 早发性卵巢功能不全的临床诊疗专家共识(2023版)
- 小学生心理健康谈心谈话记录表
- 摩托车维修维护管理制度范本
- 第3课中国特色社会主义进入新时代(高教版2023基础模块)
- 学校信息化设备管理制度(4篇)
- 人脸识别项目系统施工方案
- 数据结构-第10章-内排序
- 【施工管理】施工图变更单
- (13.1.1)-1团结人民完成各项任务的中心环节
评论
0/150
提交评论