[Mailman-Developers] Storing extra data during pipeline processing

Juraj Variny rini17 at gmail.com
Mon May 11 21:49:46 CEST 2015


Thanks, it helped me to clear the confusion. 

I have decided to modify Scrubber so that its work is split, when in normal 
pipeline it only saves the attachments to disk, does gpg stuff, but keeps 
message unchanged(only headers added). Message is then processed when called 
from archiver. 

The change came out quite trivial and I wonder why it was not done that way in 
the first place.

Juraj

On Thursday 07 May 2015 14:40:53 Mark Sapiro wrote:
> On 05/07/2015 01:59 PM, Barry Warsaw wrote:
> > On May 07, 2015, at 10:51 PM, Juraj Variny wrote:
> >> I have tried already to use msgdata parameter or adding headers to
> >> message
> >> itself, but was not successful so far. I was thinking about adding
> >> external
> >> database and putting the data there by message ID, but sure there must be
> >> a
> >> better way? I hope to publish the code some day, too.
> > 
> > Can you give some details on what didn't work about using the msgdata
> > parameter?  This always flows with the message through the pipeline and is
> > preserved in the pickle files as the message moves from runner to runner.
> > It's the way handlers are supposed to record information on the message as
> > its being processed.
> 
> See my reply in this thread. I think I understand.
> 
> > This is even more important in Mailman 3 where we've split the pipeline
> > into rules and handlers.  Rules are run to determine moderation behavior
> > and rules are never supposed to modify the message.  They communicate
> > state to (possible) later handlers via the msgdata dictionary.
> 
> In MM 3 one can have a rule which checks and verifies signatures and
> stores results in the msgdata. Than a handler can use that data to add a
> message header both for recipient info and to inform other bits that
> might run after there's no longer any msgdata dictionary traveling with
> the message.



More information about the Mailman-Developers mailing list