The last days I've worked intensively on the Lightweight Message Bus (CELLMB). After a first approach developing everything in one module it is now splitted up into three modules, one more general and two for the CELLMB. The first one is the Service Process Pool (CELSPP), which starts service processes up to a defined number. The start function returns a process ID which now can be used as if the process is only one single instance process. But instead of handling those messages itself, the received messages will be resent round robin to the service processes. So here and in its lazy automatic process creation it differs from pg2. A normal exit is resent to all service processes to terminate gracefully, also died processes are removed and recreated on demand automaticly. A later extension will support the processes to opt out and terminate after an idle time.
The CELLMB now uses this pool for the internal dispatching of messages with a given context, verb, and noun to subscribed processes. Those can be single and pooled processes using the CELSPP. For a simple development of those processes the module CELLMBSVC provides a generic behaviour. Just the callbacks init, handle and terminate have to be implemented - of course beside possibly needed helper functions.
The next step will be the implementation of the unit tests for the CELLMB and then the first services for my Erlang Business Library (EBL) which I'll use in my different portal projects. Those will handle configuration, authentication, authorization, client management, user management, and addresses based on vCards. They all will use Mnesia as their persistency backend and will be loose-coupled using the CELLMB for communication.
The CELLMB now uses this pool for the internal dispatching of messages with a given context, verb, and noun to subscribed processes. Those can be single and pooled processes using the CELSPP. For a simple development of those processes the module CELLMBSVC provides a generic behaviour. Just the callbacks init, handle and terminate have to be implemented - of course beside possibly needed helper functions.
The next step will be the implementation of the unit tests for the CELLMB and then the first services for my Erlang Business Library (EBL) which I'll use in my different portal projects. Those will handle configuration, authentication, authorization, client management, user management, and addresses based on vCards. They all will use Mnesia as their persistency backend and will be loose-coupled using the CELLMB for communication.