From: Michal L. <ml...@lo...> - 2009-08-20 12:51:21
|
Lionel Bouton wrote: > Just init the system with a very high cleanup > frequency : 30s between each cleanup for example. Then let it find the > sweet spot from that point. On most domains it should lower the cleanup > frequency gradually and only on very busy domains will it keep it around > the initial value. > Everyone would be able to use this without any configuration. > > To make that work we only have to store the db_cleandelay in the config > table in addition to the current last cleanup timestamp. > For each SQLgrey process, we wait for our own (adjusted) copy of the > delay to expire, reload the values store in DB to make sure another > process hasn't change things behind our back (then we know the cleanup > is already done) and update our own internal copy of the > next_cleanup_time based on the DB values. We set a minimum db_cleandelay > of 10s, add or remove a random number of seconds (between -5 and +5) and > we are set. Even if two or more servers happen to clean at the same > time, it's not a problem : they should all take roughly the same time > doing so (because one is blocking all the others on blocking backends or > they share the delete work on non-blocking backends) and will all put > roughly the same values in the database -> no unexpected cleandelay > shooting through the roof or the floor. Frankly this is quite a major change to be implemented in the last minute before 1.8.0. I propose to postpone it after 1.8.0 - it's been waiting for two years, it can wait a month more. There's one thing I'd like to have for 1.8.0 - support for netmasks in client_ip_whitelist[.local]. At the moment it only accepts full IP (1.2.3.4) or class-c notation (1.2.3), what I'd like to have is a prefix-based notation (1.2.0.0/16 or 10.20.30.40/28). Still accepting the current syntax as well of course. That's pretty easy to verify for correctness and should be safe to include. BTW Would you mind if I migrated the CVS repo to SVN or HG? Michal -- * http://smtp-cli.logix.cz - the ultimate command line smtp client |