[Mailman-Developers] Event notifications

Barry Warsaw barry at list.org
Thu Sep 6 03:38:00 CEST 2012


On Aug 02, 2012, at 12:13 PM, George Chatzisofroniou wrote:

>It looks like the only notification the core provides is that of new
>postings (through the IArchiver interface). It would be great if core
>could provide notifications for more events (like someone subscribed
>or a new thread started) that also carry more information (for
>postings: number of recipients and message size).
>
>So, what i suggest is basically a message bus that components can
>register for notifications. I'm not sure if this has been discussed
>before and is already in the plans.

Within the Mailman core, events are triggered using zope.event.notify().  This
is basically a very simply subscribe-notify system where class instances
represent the notifications.  A few things internally depend on this to
perform certain actions, such as removing the members of a mailing list before
that mailing list is deleted.

The idea is that plugins could subscribe to those events if they wanted to
perform additional operations when certain events occur.

I've taken a mostly organic approach to adding new events, adding them only
when needed internally.  I'm open to adding new event notifications as
necessary to support add-ons or new internal functionality.  The way to
request this is via the Launchpad bug tracker.

Cheers,
-Barry



More information about the Mailman-Developers mailing list