This is one of the options for Assignment 3.
The goal of this assignment is to build an EvenBus for distributed systems, by combining elements of an Event Notifier and a Broker.
In this variant, an event bus is placed between the publisher and the subscribers.
The publisher, event bus and subscriber can all exist in different processes. Hpwever, Publishers and Subscribers will use the same simple EventBus API (operations publish() - subscribe()). Publishing an event, subscribing to an event type, and informing a subscriber are now all remote method invocations.
Adapt the Broker architecture of ToyORB to construct such a distributed EventBus communication infrastructure.
In the figure above we see that there are 4 proxy components involved. However, in this case the proxies correspond to fixed interfaces (the remote interfaces are already known: the EventBus interface (which offers services publish() and sbscribe()) and the Subscriber Interface.)
Component A acts as a fixed clientside proxy for the remote EventBus interface.
Component B acts as a fixed serverside proxy for the EventBus interface (the publish() part of EventBus).
Component C acts as a fixed serverside proxy for the EventBus interface (the subscribe() part of it) and also as a clientside proxy for the Subscriber interface.
Component D acts as a clientside proxy for the EventBus interface and as a serverside proxy for the Subscriber interface.
Build a distributed event bus, as a generic infrastructure that can be used for building different event-driven distributed applications. These applications are unknown to the event bus, the event bus is not allowed to depend on the applications.
Your Distributed EventBus infrastructure will contain: a library to be used by application developers and an EventBus permanent server.
Prove your infrastructure by developing 2 different applications on top of it: