Progress status 12/18/2007
 

Progress on the design and the prototype implementation is going on. I now have a working prototype for the inter-object communication system. This helps me testing and refining the design. I also regularly review and update the specification documents.

On DITP, the current points of focus is to find a good way to manage the PDU (Protocol Data Units) processing like compression, authentication or enciphering. The user must be able to select and set them up in a snap while keeping it as versatile and flexible as possible.

On IDR, the current point of focus is a refinement of signed information encoding. A straightforward implementation is to simply append to signature to the signed information. But this annihilates all the benefits of the stream oriented encoding. Beside, invalid signature or data must be detected as early as possible. A solution has been identified, but fitting it nicely with the current encoding requires some more investigation.

A design process is a difficult task because we have zillion of decisions to make. The more complex the design, the more decisions there is to make, and likely we can make a mistake somewhere. The two heuristics I use to minimize this risk is first to keep the design as simple as possible and second to minimize the constrains on usage. The former is popular, the later much less.

 
 

DIS is based on the object model. DITP, the communication protocol used by DIS, is thus an inter-object communication protocol: it makes it possible to invoke methods of an object hosted in another process.

Client and service

The most simple API to do so, is to have a dummy object on the client side with exactly the same interface as the remote object. The methods of the dummy object, we'll call client, forward the call to the remote object we'll call service. Forwarding a method call means packing arguments into a message, send it to the service that process the call and sent back a message containing the result. From the user point of view there is no difference with calling a method of a local object.

In DITP the client object has an exclusive relationship with the remote service object it is connected to. The service is thus in fact an agent acting on behalf of the client. It is however still under control of the hosting process who can modulate its behavior according to client credentials or specific context. This design has also the benefit to associate a state to the service that may be transient or persistent (restored in a new connection).

Shared services are services that may be accessed by multiple clients simultaneously, Such services are implemented by a dedicated object supporting concurrent method invocations from the different services (agents).

Sequential and concurrent method invocation

Sequential method invocation is the most simple to implement and is also expected to be most frequent use case. The service process incoming method invocation requests one by one in the order of arrival, processing the next one only when the result of the previous one has been sent back. Adding a timeout control system will ensure that the system will never block.

Concurrent method invocation requires that each method invocation is processed by a dedicated thread. The service has to be thread safe and a congestion avoidance system is required in addition to the timeout control. It is thus more complex to design and implement.

DITP is designed so that simple communication models are simple to implement and use, and that more complex communication models can be implemented by composition.

Thus a client-service connection, called a channel, will only support sequential method invocation. Since DITP supports channel multiplexing and in both directions, supporting concurrent method invocation is implemented by encapsulating a pool of parallel client-service connections inside of the client and the service. Callbacks may then be implemented by multiplexing reverse client-service connections. .