Concept of Middleware

Organisation

Organisation of middleware uses two concepts.

Wrappers

Wrappers adapt a component’s functions into something that’s acceptable to the client application. It does this by offering an interface in which the client and server / component can communicate.

Interceptors

Interceptors break the usual control flow to allow other application code to be executed.

Fig. 2.14, DS, van Steen & Tenenbaum

In the above example, if object B is replicated, then the client application needs to manually keep track of all the replicas and transmit the invocation call to all of them.

With an interceptor, the Request-Level Interceptor manages these calls, so only one call is needed from the client.

Examples of Middleware

REST

Representational State Transfer is used to provide a convenient interface for services to communicate over the web. One machine acts as a client, while the other acts as a server.

Advantages of Middleware

Glossary