Sqlite2, Sqlite3, locking and friends

This Kannel patch fixes support for Sqlite2 (which was partially implemented but missed the configuration section) and also adds a new option “lock-timeout” for both [sqlite-connection] (newly added) and [sqlite3-connection] groups.

lock-timeout can be set to the number of milliseconds that sqlite waits before throwing a “BUSY” error. Because locking on sqlite is done AT THE DATABASE LEVEL, it can be a serious issue because any write operation would lock the entire database, so this option aims to ease the risk of getting locks.

If it’s not set, the default sqlite behaviour is maintained.

Here’s the patch:

kannel-sqlite-pool-patches

As usual, please try it and let me know what you think.