next up previous
Next: Remote Invocation Up: Binding Previous: Binding

Implicit v. Explicit binding

An implicit binding mechanism creates the state associated with a binding in a manner invisible to the client. An invocation which is declared to return an interface reference actually returns a closure for a valid surrogate for the interface. Creation of the surrogate can be performed at any stage between the arrival of the interface reference in an application domain and an attempt by the application to invoke an operation on the interface reference. Indeed, bindings can time out and then be re-established on demand.

The key feature of the implicit binding paradigm is that information about the binding itself is hidden from the client, who is presented with a surrogate interface indistinguishable from the `real thing'. This is the approach adopted by many distributed object systems, for example Modula-3 Network Objects [25] and CORBA [26]. It is intuitive and easy to use from the point of view of a client programmer, and for many applications provides all the functionality required, provided that a garbage collector is available to destroy the binding when it is no longer in use.

On the other hand, traditional RPC systems have tended to require clients to perform an explicit bind step due to the difficulty of implementing generic implicit binding. The advent of object-based systems has recently made the implicit approach prominent for the reasons mentioned above. However, implicit binding is inadequate in some circumstances, due to the hidden nature of the binding mechanism. It assumes a single, `best effort' level of service, and precludes any explicit control over the duration of the binding. Implicit binding can thus be ill-suited to the needs of time-sensitive applications.

For this reason, within Nemesis bindings can also be established explicitly by the client when needed. If binding is explicit, an operation which returns an interface reference does not create a surrogate as part of the unmarshalling process, but instead provides a local interface which can be later used to create a binding. This interface can allow the duration and qualities of the binding to be precisely controlled at bind time with no loss in type safety or efficiency. The price of this level of control is extra application complexity which arises both from the need to parameterise the binding and from the loss of transparency: acquiring an interface reference from a locally-implemented interface can now be different from acquiring one from a surrogate.


next up previous
Next: Remote Invocation Up: Binding Previous: Binding

I. Leslie, D. McAuley, R. Black, T. Roscoe, P. Barham, D. Evers, R. Fairbairns & E. Hyden