台北科技大学:《计算机网络》(英文版) NP04 22(comer)

Distributed Program Generation(rpcgen Concept) Chuan-Ming liu CSIE NTUT Spring 04, TAIWAN
1 Distributed Program Generation (rpcgen Concept) Chuan-Ming Liu CSIE, NTUT Spring ’04, TAIWAN

Introduction )Focuses on the structure of programs that use RPC, and shows how program can be divided along procedure boundaries INtroduces the stub procedure concept and a program generator tool that automates much of the code generation associated with ONC RPC DIt also discusses a library of procedures that makes it easy to build servers that offer remote procedures and clients that call them
2 Introduction Focuses on the structure of programs that use RPC, and shows how program can be divided along procedure boundaries Introduces the stub procedure concept and a program generator tool that automates much of the code generation associated with ONC RPC It also discusses a library of procedures that makes it easy to build servers that offer remote procedures and clients that call them

Using rPcs D The RPC model is general )A programmer can choose to use the remote procedure paradigm in any of the tollowing ways DAS a program specification techniques only D For both program specifications and as an abstraction during program design
3 Using RPCs The RPC model is general A programmer can choose to use the remote procedure paradigm in any of the following ways: As a program specification techniques only For both program specifications and as an abstraction during program design

Using rPcs(cont) O For the conceptual design and explicitly in the implementation D For design and implementation, constructing all software from scratch D For design and implementation, using standard libraries D For an automated implementation
4 Using RPCs (cont.) For the conceptual design and explicitly in the implementation For design and implementation, constructing all software from scratch For design and implementation, using standard libraries For an automated implementation

Programming mechanisms to Support RPC IMplementations of ONC RPC provide significant help for those who wish to avoid unnecessary programming ASsistance comes in four forms D XDR library routines that convert individual data items from internal form to the Xdr standard external representation
5 Programming Mechanisms to Support RPC Implementations of ONC RPC provide significant help for those who wish to avoid unnecessary programming Assistance comes in four forms: XDR library routines that convert individual data items from internal form to the XDR standard external representation

Programming Mechanisms to Support rPC(cont) D XDR library routines that format the complex data aggregates(e.g, arrays and structures) used to define rPc messages ORPC run-time library routines that allow a program to call a remote procedure, register a service with the port mapper or dispatch an incoming call to the correct remote procedure inside a remote program a program generator tool that produces many of the c source files needed to build a distributed program that uses rPc
6 Programming Mechanisms to Support RPC (cont.) XDR library routines that format the complex data aggregates (e.g., arrays and structures) used to define RPC messages RPC run-time library routines that allow a program to call a remote procedure, register a service with the port mapper, or dispatch an incoming call to the correct remote procedure inside a remote program A program generator tool that produces many of the C source files needed to build a distributed program that uses RPC

Programming Mechanisms to Support rPC(cont) )The RPC run-time library has procedures that supply most of the functionality needed for rpc ) For example, procedure callrpc sends an RPC message to a server Dcallrpc(host, prog, prover procnum, inproc, in, outproc, out
7 Programming Mechanisms to Support RPC (cont.) The RPC run-time library has procedures that supply most of the functionality needed for RPC For example, procedure callrpc sends an RPC message to a server callrpc(host, prog, progver, procnum, inproc, in , outproc, out);

Programming Mechanisms to Support rPC(cont) Da client calls function cInt create to create an integer identifier(called a handle that can be used to send rPC message Handle=cInt create(host, prog, vers, proto) ) Several RPC library pi rocedures take a handle as one of their argument
8 Programming Mechanisms to Support RPC (cont.) A client calls function clnt_create to create an integer identifier (called a handle) that can be used to send RPC message: handle = clnt_create(host, prog, vers, proto) Several RPC library procedures take a handle as one of their argument

Programming Mechanisms to Support rPC(cont) D The library library also contains routines that create store, and manipulate authentication information PFor example, procedure authunix creates an authentication handle for a given use on a given host computer Dauthunix create(host, uid gid, len, aup gids D Most programmers rely on the program generator tool to generate a code that contains calls to the library procedures
9 Programming Mechanisms to Support RPC (cont.) The library library also contains routines that create, store, and manipulate authentication information For example, procedure authunix creates an authentication handle for a given use on a given host computer authunix_create(host, uid, gid, len, aup_gids) Most programmers rely on the program generator tool to generate a code that contains calls to the library procedures

Dividing a program into local and remote procedures DFig. 22. 1 illustrates an example procedure call that shows the procedural interface used by a calling procedure and a called procedure D The dashed lines denote a match(the total number and types )between arguments in the procedure call and formal parameters in the called procedure
10 Dividing a Program into Local and Remote Procedures Fig. 22.1 illustrates an example procedure call that shows the procedural interface used by a calling procedure and a called procedure The dashed lines denote a match (the total number and types) between arguments in the procedure call and formal parameters in the called procedure
按次数下载不扣除下载券;
注册用户24小时内重复下载只扣除一次;
顺序:VIP每日次数-->可用次数-->下载券;
- 台北科技大学:《计算机网络》(英文版) NP04 21(comer).ppt
- 台北科技大学:《计算机网络》(英文版) NP04 20.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 20(comer).ppt
- 台北科技大学:《计算机网络》(英文版) NP04 2 CONTENTS.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 18.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 16 server ex con.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 16 server ex.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 16 server.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 16 multi services.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 16 multi proto.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 16 Client Software Design.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 16 Socket API.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 15 Client Server model.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 12 CONTENTS.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 11 Introduction.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 1 CONTENTS.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 0 Network Programming.ppt
- 哈尔滨工业大学:《网络应用开发》英文版 网络开发与应用实验指导书.pdf
- 哈尔滨工业大学:《网络应用开发》英文版 NAD-chapter7.pdf
- 哈尔滨工业大学:《网络应用开发》英文版 NAD-chapter7-6.pdf
- 台北科技大学:《计算机网络》(英文版) NP04 23(comer).ppt
- 台北科技大学:《计算机网络》(英文版) NP04 24(comer).ppt
- 台北科技大学:《计算机网络》(英文版) NP04 27 Mobile ip discussion overview.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 28 Real-Time Transport protocol.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 3 CONTENTS.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 4 CONTENTS.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 5 Subnetting.ppt
- 台北科技大学:《计算机网络》(英文版) NP04 8 Internet Protocol (IP).ppt
- 《计算机图形学》课程教学资源:第3章 图形的基本运算.ppt
- 《计算机图形学》课程教学资源:第4章 图形的观察运算.ppt
- 《计算机图形学》课程教学资源:第6章(6-1)图形的数据结构.ppt
- 《计算机图形学》课程教学资源:第6章 图形的数据结构.ppt
- 《计算机图形学》课程教学资源:第7章 三维图形显示基础.ppt
- 《计算机图形学》课程教学资源:第10章 光照物体的显示.ppt
- 《计算机图形学》课程教学资源:颜色.ppt
- 《计算机图形学》课程教学资源:2003-2004计算机图形学试卷(A).doc
- 《数学与应用数学》2003-2004数学与应用数学试卷(A).doc
- 《计算机图形学》课程教学资源:2003-2004计算机图形学试卷(B).doc
- 《计算机图形学》课程教学资源:2003-2004计算机图形学试卷(B)答案.doc
- 《计算机图形学》课程教学资源:计算机图形学(A).doc