[Mailman-Developers] Hooks for external archivers

Gareth McCaughan gmccaughan at synaptics-uk.com
Thu Jun 1 13:01:11 CEST 2006


Suppose you're using Mailman with a separate archiving system
such as Lurker or mod_mbox or something. Then there are a few
points at which the external archiver needs to be informed of
what Mailman is up to, including at least these:

  - Creation of a new list
  - Some changes to config of an existing list
  - Arrival of a new message
  - Removal of a list (maybe)

At the moment (I'm using 2.1.8) I think the only such notification
is for the arrival of a new message, at which point PUBLIC_EXTERNAL_ARCHIVER
or PRIVATE_EXTERNAL_ARCHIVER gets invoked.

In my local setup, I've tentatively added a new hook that I've
equally tentatively called LIST_INFO_UPDATE_COMMAND; if it's not
None, it gets invoked whenever a list object's Save method is
called (after %-formatting using the list's configvars plus an
extra entry for the list's canonical name). That works well
for my needs, but I'm under no delusion that it's clearly optimal.

Is there a Right Thing that I should have done instead? If not,
should Mailman grow some more hooks for interaction with external
archivers?

(Here's a possibly tempting Wrong Thing: don't have separate hooks,
just check everything whenever a new message arrives. But this is
inefficient, and more importantly it means that changes to list
information won't be noticed until the next message is sent, which
for low-traffic lists might be some time after the change.)

-- 
g



More information about the Mailman-Developers mailing list