[Mailman-Developers] Mysql MemberAdaptor, v1.27
kyrian-list at ore.org
Sat Nov 8 07:02:36 EST 2003
I was planning to, but I couldn't work out where to put it either. More
research (or another API hook in mailman?) will be required methinks...
In theory MySQL should time them out after a while, but that's a bit of
an unacceptable risk, really, since people might have lists that
regularly get mailed to, and hence call the __init function, thus
connection-flooding MySQL and causing it all to break down and go to
I also found a stupid bug in the Mysql bounce handling(again) which I've
fixed and uploaded.
The guy using this thing was supposed to give me a heads-up before using
it on his list this morning, but didn't, so I can only assume it's all
been going okay so far, since he didn't complain at me about it not
On Sat, 8 Nov 2003 04:29:20 +0800
"Yuan, Cain" <cain.yuan at intel.com> wrote:
> Hi Kev,
> It's very cool to do a ping() before using those connections.
> One more question here: where are you planning to add the code
> for close those connections when mailman is ready to quit
> (sometimes we need to shutdown mailman manually and of cause we
> did not want to leave those connection in the system)? Python
> has a __init() but seems no __exit functions( correct me if I
> am wrong).
> -----Original Message-----
> From: mailman-developers-bounces+cain.yuan=intel.com at python.org
> [mailto:mailman-developers-bounces+cain.yuan=intel.com at python.org]On
> Behalf Of Kyrian (List) Sent: Saturday, November 08, 2003 1:40 AM
> To: mailman-developers at python.org
> Subject: [Mailman-Developers] Mysql MemberAdaptor, v1.27
> > Hi Kev,
> > I had a look at the patch and have some questions here: why you
> > establish a connection to MySQL and then close it in each
> > function? AFAIK this will put much presure on MySQL if there
> > are some people to subscribe/unscribe from the list. Why not
> > just establish a ststic link to MySQL and then use it every time
> > you need to access the DB?
> > Cain
> In response to this, and the atrocious performance that I just
> observed sending to a 60,000 or so member list, I've implemented a
> connection sharing system in v1.27.
> I've removed all the explicit connect/cursor calls, and now they're
> implemented by a connect on __init() and subsequently by a single
> function; prodServerConnection() which does a ping() against the
> server(which the MySQL docs say should do an automatic reconnect if
> possible), checks for errors, if the ping() fails, tries a full
> disconnect and reconnect, trapping any errors that occur.
> If that fails, it drops out.
> This hasn't been thoroughly tested yet, but it should work I think.
> I still need a little help with the bounce_info and delivery_status
> flags, though, as they don't seem to be working, in spite of what
> Mailman is logging(*), the database isn't being updated.
> *) Lots of these, but the database isn't being updated properly...
> Nov 07 17:25:14 2003 (6195) XYZ at MYDOMAIN.co.uk: test current bounce
> score: 1.0
> Kev Green, aka Kyrian. "Be excellent to each other" -- Bill &
> Email: firstname.lastname@example.org Web: http://kyrian.ore.org/
> ISP/Perl/PHP/Linux/Security Contractor, via http://www.orenet.co.uk/
> Mailman-Developers mailing list
> Mailman-Developers at python.org
Kev Green, aka Kyrian. "Be excellent to each other" -- Bill & Ted.
Email: email@example.com Web: http://kyrian.ore.org/
ISP/Perl/PHP/Linux/Security Contractor, via http://www.orenet.co.uk/
More information about the Mailman-Developers