Bojan Smojver wrote:
After running some tests with worker MPM against SQLite3 database, it
turns out that performance can be improved by doing linear backoff in
the wait loop (although SQLite is still quite bad when it comes to
highly concurrent apps). Patch is attached.
Comments?
This is similar to what SQLite3 does internally if you call
sqlite3_busy_timeout() after sqlite3_open().
See the sqliteDefaultBusyCallback() function in the SQLite3 source file main.c.
ref: http://www.sqlite.org/c3ref/busy_timeout.html
Calling sqlite3_busy_timeout() in dbd_sqlite3_open might be better than using
the
do { ... apr_sleep() ... }
loop in dbd_sqlite3_select_internal.
The sqlite3_busy_timeout() function has been in SQLite since version 3.0, so no worries about
someone having an older version.
Nevertheless, I also see that SQLite is quite slow for concurrent updates; despite being very fast
for reads.
-tom-