Page 1 of 1

Minus One (-1) Remaining Message Total

PostPosted: Fri Sep 01, 2006 8:14 pm
by ckent
Hello,

In my list of disposable messages, one email address shows -1 (minus one) messages remaining, while the others show just zero. Is there a reason this would happen? First time I've seen this since I've started using spamgourmet a few years ago.

Thanks!

PostPosted: Sun Sep 03, 2006 3:21 am
by SysKoll
"Race condition". This is the perfect textbook example. You get two emails addressed to the same disposable. The two mail processes check the DB for this disposable's counter, which is 1. Normally, each process would then decrement the counter, but here, each was interrupted long enough so that the other could also check the counter.

Afterwards, both of them decrement the counter, which goes to -1.

We don't lock the DB to improve performance. So this stuff can theorically happen and just did.

PostPosted: Sun Sep 03, 2006 5:06 am
by josh
That address is really, really expired :) -- do a whois on spamgourmet.com, and you'll notice the name servers on the domain minusone.net - but that's not really related to what you're describing. Syskoll said it - race condition that we believe is better left unfixed.