Decoupling Seaside Components

A problem that is frequently discussed on the Seaside mailing-list is how to navigate and communicate between different components without increasing the coupling. The most obvious solution, direct references, tightens the coupling and hampers reuse of these components in different contexts.

For quite some time I have been successfully using Announcements in the context of Web applications. Even-tough this framework has not been designed for the Web it turns out to be extremely versatile: Any part of the application (such as components) can register for a specific or a group of events to be notified about. The model, or other components can then trigger events that get propagated to the interested parties. To take it even one step further, announcements allow to pass data around easily, and even communicate between different sessions. Moreover they work well together with Seaside’s server push technology.

Currently there are at least three different implementations of Announcements available in Squeak for you to try out:

  • A minimal implementation as part of the OmniBrowser framework.
  • An extended version of the initial OmniBrowser implementation slightly generalized and separately packaged.
  • A complete port of the original announcement framework as found in VisualWorks.
Posted by Lukas Renggli at 16 February 2007, 9:28 pm with tags seaside link

Comments

Hi Lukas,

would be cool if you can tell us what is the implementation you choosed, why, and how can we use it.

Thank you very much for you blog, I really appreciate its reading.

Bye

Posted by Damien Cassou at 17 February 2007, 10:23 am link

Thanks for the comments to both of you.

Damien, I planned to give some examples later on.

Balázs, sorry for not being aware that your code is not a port. Thanks for posting your example, is there a chance that your framework gets published? I haven’t been combined Scriptaculous and Announcements yet, I used it more on the level of components and the domain model to propagate changes between different parts of the application.

Posted by Lukas Renggli at 17 February 2007, 7:45 pm link

Comments seem to disappear randomly. Anybody is experiencing this?

Posted by Balázs Kósi at 17 February 2007, 11:58 pm link

Balázs, thanks for posting your AJAX development. I will certainly have a look at.

For the missing comments I don’t know. This must be a strange bug in the blog component as it didn’t happen the first time. I restored the comments that disappeared and will try to reproduce and fix the issue as soon as possible.

Posted by Lukas Renggli at 18 February 2007, 12:18 am link