monotone-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Monotone-devel] mtn: error: sqlite error: database is locked


From: Peter Stirling
Subject: Re: [Monotone-devel] mtn: error: sqlite error: database is locked
Date: Wed, 26 Dec 2007 20:38:48 +0000

Normally write transactions are exclusive because of the infamous 'two withdrawals from your bank account' example.

When you change a value you need to be able to stop others from changing it again when you don't expect them to.

On 26 Dec 2007, at 6:30 pm, Alvaro Herrera wrote:

Zack Weinberg wrote:
On Dec 25, 2007 6:32 PM, Alvaro Herrera <address@hidden> wrote:

Why would the database care?  If the appropriate constraints are in
place, the database itself would alert Monotone when an operation it is
attempting would conflict with another ongoing operation.

In the present state of the code, Monotone wraps every access to the
database in an EXCLUSIVE transaction.  The work you are dismissing as
unnecessary-if-only-we-used-a-different-backend is the work needed to
make it not do that.

Oh, I see. To be honest this is the first time I hear about "exclusive
transactions".  The concept does not really make much sense to me.
Perhaps in the SQLite view of the world it does.

--
Alvaro Herrera      Valdivia, Chile           Geotag: -39,815 -73,257
"No necesitamos banderas
No reconocemos fronteras"                  (Jorge González)


_______________________________________________
Monotone-devel mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/monotone-devel

--
This email has been verified as Virus free.
Virus Protection and more available at http://www.plus.net





reply via email to

[Prev in Thread] Current Thread [Next in Thread]