#1 2013-06-24 11:31:40

Kobe
Member
Registered: 2013-04-08
Posts: 38

LockingMode to lmExclusive

Hello friends,

When I change the LockingMode to lmExclusive, does it make the database more likely to corruption, in case of an external issue, such as hardware failure?

Thank you

Offline

#2 2013-06-24 12:30:11

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,240
Website

Re: LockingMode to lmExclusive

If you set only lmExclusive, it should be almost as ACID as by default.

But less than with the default mode, by design.

I suspect it is as safe as most database engines, e.g. FireBird or even MSSQL/Oracle.

Offline

#3 2013-07-24 11:22:21

Roberto Schneiders
Member
From: Santa Catarina, Brazil
Registered: 2012-09-19
Posts: 127
Website

Re: LockingMode to lmExclusive

I'm trying to do some tests to compare the performance of SQLite vs Firebird Embedded.

I wish the two worked with the same kind of synchronization.
According to this article (http://blog.synopse.info/post/2013/06/1 … cking-mode) I should use this:

better Security:
Client.Server.DB.LockingMode := lmExclusive;
Client.Server.DB.Synchronous := smFull;

best Performance
Client.Server.DB.LockingMode := lmNormal;
Client.Server.DB.Synchronous := smOff;

Is that right?

The first problem is that I have not found the property "DB.LockingMode".

Have any way to set the framework to work the same way with the two databases? To be a fair test!

Offline

#4 2013-07-24 17:56:32

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,240
Website

Re: LockingMode to lmExclusive

You need to retrieve the latest "unstable" version of mORMot to have all needed properties.

To have a "fair" test, what you can do is define the table as external.
Then use an SQLite3 external table, and  a FireBird external table.
It is exactly what the performance test sample does.

Offline

#5 2013-07-24 19:10:31

Roberto Schneiders
Member
From: Santa Catarina, Brazil
Registered: 2012-09-19
Posts: 127
Website

Re: LockingMode to lmExclusive

Sorry. I thought was in last version. But there were some read-only sources (my fault).  When performing "Fossil Update" he did not warned me. I thought it was updated, but it was not. hmm

Offline

Board footer

Powered by FluxBB