directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vincent Tence <>
Subject Re: [RT] Notification pattern has interesting effects on IoC
Date Wed, 18 Feb 2004 01:23:48 GMT
On Wed, 2004-02-18 at 04:44, Alex Karasulu wrote:
> Hi all,
> While looking at the frontend of the Eve server I began to realize a trend
> emerging after I introduced a central publish and subscribe facility. The
> pattern decouples components by enabling communication using events and the
> notifier pattern. This also lead to the disappearence of methods on service
> interfaces. 
> So the dependency graph turns into a star with all components depending on
> the event router, hub, bus or whatever you call it in the center. Event
> types and interfaces essentially become the dependency as opposed to the
> service interfaces. This way you can introduce new subscribers and
> publishers. Also the dynamic rerouting of events is possible at runtime.
> What this means is that the dependencies between components can change on
> the fly! Wow not a bad thang. 
> What does this mean for service interfaces? Well they start looking bleak
> because the Subscriber interface replaces them. Basically methods are called
> internally by the Subscriber handling code on the component itself rather
> than exposing them on the service interface for direct calls by what are now
> publishers. This is crazy my service interfaces are all empty now! 

Which is cool, cuz it means yours components can be POJOs. Can you wire
the entire system at startup and get rid of the need to support
different component frameworks? Only the bootstrap mechanism would be
dependant of the kernel used.

> Alex

View raw message