From 76a8d2acaf0255ffdf37ae0eccfc6e00f4c23f32 Mon Sep 17 00:00:00 2001 From: bwarsaw Date: Sat, 22 Jul 2000 02:39:00 +0000 Subject: process(): Addressing both SF bug #108167 and patch #100861, this patch writes success and failure messages to logs/post. It retains the writing of smtp delivery timing messages to logs/smtp. --- Mailman/Handlers/SMTPDirect.py | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/Mailman/Handlers/SMTPDirect.py b/Mailman/Handlers/SMTPDirect.py index cc6f972e7..b9f75eca1 100644 --- a/Mailman/Handlers/SMTPDirect.py +++ b/Mailman/Handlers/SMTPDirect.py @@ -75,9 +75,19 @@ def process(mlist, msg, msgdata): finally: t1 = time.time() mlist.Lock() - # Process any failed deliveries. + # Log the successful post syslog('smtp', 'smtp for %d recips, completed in %.3f seconds' % (len(recips), (t1-t0))) + + if refused: + syslog('post', 'post to %s from %s, size=%d, %d failures' % + (mlist.internal_name(), msg.GetSender(), len(msg.body), + len(refused))) + else: + syslog('post', 'post to %s from %s, size=%d, success' % + (mlist.internal_name(), msg.GetSender(), len(msg.body))) + + # Process any failed deliveries. tempfailures = [] for recip, (code, smtpmsg) in refused.items(): # DRUMS is an internet draft, but it says: -- cgit v1.3.1