Network Objects Andrew Birrell, Susan Owicki, and Edward Wobber - 1993 ------------------------------------------------------ Summary: This paper presents the design and implementation of a distributed system that uses object-oriented RPC as the method of communication. Definition: A network object is an object whose methods can be invoked over a network. Introduction: Object-oriented programming applies naturally to distributed computing, since the method calls are a convenient place to insert the communication required by the distributed system. Questions: Should objects be... - Mobile or stationary? - Communicated by copying or by reference? - Active? - Persistent? - Replicated? - Is there any difference between inter-program typechecking and intraprogram typechecking? - Key simplification: objects are not mobile. What about the other questions? They do not seem to be addressed. Features: This system is simple because they restricted the feature set to those features that are valuable to all distributed applications. - Powerful marshalling - Strong type-checking - Garbage collection - Efficent and convenient access to streams These are the features that were omitted because they were more complex and/or their usefulness more speculative: - Transactions - Object migration - Distributed shared memory Object-oriented RPC: 1. Client program calls methods in a local surrogate object. 2. The surrogate object performs remote procedure calls to the network object. A surrogate object has the same interface as the network object it represents and is created by a stub generator. The stub generator uses inheritance to override the methods in the network object interface to create the surrogate object that performs RPC calls. Marshaling: - It's difficult to provide fully general marshaling code. Current solutions include: 1. Applying restrictions to the types of object that can be marshaled, typically prohibiting linked, cyclic, or graph-structured objects. 2. Generating elaborate code for almost any data type; however, the resulting stub modules are excessively large and inefficient. - Solution: Produce in-line code for simple types (for efficiency) and use a pickle package to produce code for complicated types (for compactness of stub code). Finally, when the default behavior is unsatisfactory, the client can specify custom procedures for marshaling. Differences between conventional RPC and object-oriented RPC: - In conventional RPC systems, it is an error to pass a context handle to any server but the one that created it. - In conventional RPC systems, it is difficult for a single address space to be both a client and a server of the same interface.