locking again

Gyepi SAM gyepi at praxis-sw.com
Sat Dec 14 05:56:30 CET 2002


On Fri, Dec 13, 2002 at 11:27:58PM +0100, Matthias Andree wrote:
> Could you have a look at
> http://sourceforge.net/tracker/index.php?func=detail&aid=653420&group_id=62265&atid=499997
> 
> David Saez suggests using BDB's native locking rather than fcntl. Would
> that be possible for our setup? Would it bring any advantage?

Even if we used BDB's lock subsystem, David would still have the
same problem: We must lock the database exclusively in order to update
it, otherwise we get inconsistent results. As long as the spamicity
analysis depends on the number of words and the number of messages,
this must be so.

What would help, however, is for us to use transactions. This would isolate
bogofilter instances from each other and then we would not have to lock the
databases ourselves. Since transactions are only available in newer BDB,
we would be omitting support for older versions. I seem to recall you saying
at some point that bogofilter does not build on older versions anyway, so this
may not be a new loss. I get the sense that most people are using newish versions anyway. I am sure someone will correct me if I am mistaken.

In the mean time, I would recommend to David to run the long training sessions
on separate databases, then merge those into the regular database, using bogoutil.

-Gyepi




More information about the bogofilter-dev mailing list