[Mailman-Developers] [Mailman-Developters] GSoC support

Barry Warsaw barry at list.org
Tue Mar 8 09:51:45 EST 2016


On Mar 06, 2016, at 12:29 AM, Abhilash Raj wrote:

>Right now, Mailman sends each email it receives to the (enabled)
>Archivers through a POST request. We want to have a pub/sub kind of
>model for the emails as well as some of the events that other archivers
>or apps built on top of mailman can consume. Events like ListCreated,
>ListRemoved or something like that.

>On 03/06/2016 12:19 AM, amil shanaka wrote:
>> Hi,
>> thank you for your reply. other than that can we use any open source
>> packages like netty and what prototype do we need to implement regarding
>> pub/sub .. MQTT or AMQP ?   
>
>The idea is to make a common interface that can use any messaging
>back-end that does the Job. I guess MQTT is meant for high latency and
>unreliable network, not much of our use case, so AMQP should be more
>relevant. However, I am not very aware about the current trends in the
>message passing and pub/sub models out there right now.

Something to keep in mind is that internally, the core already employs
zope.events to inform non-local components when certain things happen.

A good example is ConfigurationUpdatedEvent which gets emitted in the
_post_process() method of the Configuration class.  Thus components like the
i18n infrastructure and language manager, the switchboards, style managers,
etc. can respond to the event.

More events can certainly be added, but we already have events such as
ListCreatingEvent/ListCreatedEvent, ListDeletingEvent/ListDeletedEvent, and
AcceptEvent, which is used when the message is accepted for posting, but is as
yet unprocessed by the handler pipeline.

One important implementation detail is that it's currently not very convenient
to register new event subscribers.  mailman.app.events.initialize() is where
this happens, but it's all hard coded.  Ideally there would be a .cfg/.ini
file or some such that this would read dynamically to add new event
subscribers.

Anyway, with all that, I think you could fairly easily write a pubsub
component that responded to the events you care about.

Cheers,
-Barry


More information about the Mailman-Developers mailing list