If you're using a recent version of MONO then I assume you're using System.Data.SQLite from Robert Simpson which is now bundled with MONO, right? I use a custom version of the same provider which has connection pooling implemented in the wrapper. We've found it to be a huge performance improvement for our typical business application since most user requests include a small number of short database queries. The time to establish a connection varies by schema and with ours we measured it at 17ms, so saving 17ms on every db call is huge (especially since most db calls average under 1ms).
There have always been some warnings about using connections across threads but I think as long as the pool is managed properly and an individual connection is only used on one thread at any given time and all statements are properly closed before being released back to the pool, there are no problems. We've done a lot of testing and haven't run into any troubles. We'll be releasing our customized version of SQLite.NET wrapper with connection pooling as soon as we have some time to integrate the latest SQLite & SQLite.NET versions. BTW, I would request you make a post on the official System.Data.SQLite forum since the author hasn't expressed any interest in connection pooling yet even though there has been a lot of community interest (he does read this list as well though). http://sqlite.phxsoftware.com/forums/thread/3011.aspx HTH, Sam ------------------------------------------- We're Hiring! Seeking a passionate developer to join our team building products. Position is in the Washington D.C. metro area. If interested contact [EMAIL PROTECTED] -----Original Message----- From: Dinesh Ramdass [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 10, 2007 3:56 AM To: sqlite-users@sqlite.org Subject: [sqlite] How to implement connection pooling HI , *How we use SQlite:* We use MONO and SQLite 3 for our project which runs on Linux. It is going to be used as an embedded database in a device. *What i want to do:* I want to use connection pooling either using some feature provided by SQLite or someone else *What i want to know:* I read in SQLite FAQs that we can have multiple connections. But there was a limitation with using same connection across threads. I think that u were referring to use of Connection pooling. So my question is around this *Question 1:* Does SQLite direct provide support for connection pooling in form of any library or opensource binary? *Question 2:* If there is no direct support for connection pooling, then is it becos we should not use? Does SQLite not advise the use of implementing connection pooling? *Question 3:* If my database access is going to be often but only for 5-6 rows CRUD operation at a time, then do u advice me to open a new connection and close it after use instead of maintaing an open connection for a long time or resetting a connection using timeout? Kindly reply A.S.A.P. Its pretty urgent . *Also i need to give a justification for not implementing CONNECTION POOLING to my client.* Kinldy provide me a justification. be Happy, Dinesh. ----------------------------------------------------------------------------- To unsubscribe, send email to [EMAIL PROTECTED] -----------------------------------------------------------------------------