Which again goes to the hardware question. If your database is on "spinning 
rust" as people call it, you can't commit a transaction (that changed the data) 
any quicker than 2 rotations of the physical disk, because the data needs to 
get synced to the disk before the next write transaction can start. So a 7,200 
rpm drive is hard limited to what, 60 commits per second? (Someone will correct 
me if I'm wrong)

Inside a transaction you can work on the cache and go as fast as you want, it's 
just when you go to save your work at the end that you have to wait.

There is a pragma (synchronous) where you can set it to not wait for a sync to 
complete and to just keep going if you're ok with something being told that it 
committed despite it potentially not actually being saved to disk yet. (Which 
is fine for a lot of things) I _think_ then that there's no delay between write 
transaction A committing and write transaction B starting. (Again, someone will 
correct me if I'm wrong)



-----Original Message-----
From: sqlite-users [mailto:sqlite-users-boun...@mailinglists.sqlite.org] On 
Behalf Of Simon Slavin
Sent: Friday, May 03, 2019 11:34 AM
To: SQLite mailing list
Subject: Re: [sqlite] [EXTERNAL] Re: seeking information on the throughput 
requirement using Sqlite

On 3 May 2019, at 4:26pm, Zhu, Liang [AUTOSOL/ASSY/US] <liang....@emerson.com> 
wrote:

> The planning transition rate is 1ms per 34-40Kb data,  we only have one 
> connection trying to write to the database.   If we have two connection, will 
> we running to database concurrency issue?

If you have normal hardware, using one connection to do all your writing will 
be simpler and allow you to use faster settings.  You can have one writing 
connection and many reading connections without slowing down access.  If you 
want to use two writing connections they may have to wait for one-another.
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to