diff options
| author | bwarsaw | 2001-06-27 22:59:42 +0000 |
|---|---|---|
| committer | bwarsaw | 2001-06-27 22:59:42 +0000 |
| commit | 083048a5fa8ed092bb9a6ec27ff7c6e02d28cbc0 (patch) | |
| tree | 4ad5782730206d1634e91b163c1c33113c593cb2 /scripts/mailcmd | |
| parent | 2a216a91521b38348b44467bcbe157f210b23765 (diff) | |
| download | mailman-083048a5fa8ed092bb9a6ec27ff7c6e02d28cbc0.tar.gz mailman-083048a5fa8ed092bb9a6ec27ff7c6e02d28cbc0.tar.zst mailman-083048a5fa8ed092bb9a6ec27ff7c6e02d28cbc0.zip | |
Performance enhancement. In order to save on the time it takes to
parse and generate the plain text message each time it's enqueued or
dequeued, we now use a binary cpickle as the message representation
file. This is controlled by a module global SAVE_MSGS_AS_PICKLES
which defaults to 1. When a message is saved as a pickle, its
extension will be .pck instead of .msg. dequeuing will automatically
recognize the different message formats and load accordingly.
Specific changes include:
enqueue(): If SAVE_MSGS_AS_PICKLES is set and the message metadata
does not have a "_plaintext" key, then the message object is stored as
a binary cpickle dump for speed. The incoming scripts post, join,
leave, etc. will set the _plaintext key because they funnel the text
straight from stdin to the .msg file, and the message text is only
parsed on the first dequeue from qfiles/in.
dequeue(): First try to load and unpickle the .pck file, falling back
to loading and parsing the .msg text file if the former is missing.
Diffstat (limited to 'scripts/mailcmd')
0 files changed, 0 insertions, 0 deletions
