Discussion about Mailman plugins(GSOC 2015)
Prakash kumar writes:
As mentioned on the ideas page I read the working of both chains.py and pipelines.py and understood the basic architecture of mailman.
I'm really having trouble with this interest in "plugins" as opposed to "rules for chains" and "handlers for pipelines". To install a rule or handler is a three-step process done by the site administrator:
Write or download a module containing some code using a simple plugin API; the code has access to all Mailman features.
Save/copy the module to .../rules or .../handlers.
Configure the global pipeline in mailman.cfg or individual pipelines in list configurations.
That looks rather "pluggable" to me. What does a "plugin" give that improves on this process?
On Mar 05, 2015, at 03:09 PM, Stephen J. Turnbull wrote:
I'm really having trouble with this interest in "plugins" as opposed to "rules for chains" and "handlers for pipelines". To install a rule or handler is a three-step process done by the site administrator:
Write or download a module containing some code using a simple plugin API; the code has access to all Mailman features.
Save/copy the module to .../rules or .../handlers.
Configure the global pipeline in mailman.cfg or individual pipelines in list configurations.
That looks rather "pluggable" to me. What does a "plugin" give that improves on this process?
Not much, but a little. Right now you'd have to drop the module into the rules or handlers subdirectory, but that's a bit of a problem because you're conflating code provided by Mailman with custom code from the sysadmin. Think of a Linux distro package - you really don't want sysadmins messing with the source tree of Mailman.
Ideally, there would be a way to add additional filesystem -- or Python import -- paths to the config files which Mailman would then search for additional rules, handlers, etc.
Right now these search paths are hardcoded, e.g. mailman/core/rules.py. That's fine for finding the standard rules, but doesn't work so well for finding custom ones.
This isn't a GSoC sized project on its own though.
Cheers, -Barry
participants (2)
-
Barry Warsaw
-
Stephen J. Turnbull