Hello David, Wednesday, August 3, 2011, 2:23:28 PM, you wrote:
> On Wed, 3 Aug 2011 21:15:16 +0200 > "Giampaolo Tomassoni" <giampa...@tomassoni.biz> wrote: >> > Except that in real life, the write transaction lasts much longer, >> What is it? 60ms? Granted. It is still a 1/100 of 6s. > No, write transactions are expensive because they (should) invoke > a fsync() system call. On a system with several contending processes > and busy disks, that can take hundreds of milliseconds or more. > Again, I'm speaking from experience here. I'm not just theorizing. >> Ok. Let me see where in the code you see the transaction is completed >> soon after the token scores are fetched. > I'm not familiar enough with the SpamAssassin code to go searching > (nor do I care since we use neither SQL nor SA for Bayes.) > I don't see any commits in the read path, however. If MySQL > automatically opens a transaction whenever you do a SELECT, > then yes... that could be a problem. I set MySQL to log all SQL queries. There has not been one query contained within a transaction. MySQL supports this by doing a START TRANSACTION which can lead to COMMIT and ROLLBACK. Previously, there was an SA plugin that supported wrapping the queries within transactions. Perhaps this is what's being used... -- Best regards, Duane mailto:du...@duanemail.org