Re: [sqlite] System.Data.SQLite and pooling problem

2012-05-02 Thread Joe Mistachkin
The fixes for this issue have now been merged to trunk along with an appropriate test case that can reproduce the issue. https://system.data.sqlite.org/index.html/ci/ae1f4354e4?sbs=0 -- Joe Mistachkin ___ sqlite-users mailing list

Re: [sqlite] System.Data.SQLite and pooling problem

2012-05-01 Thread Larry Brasfield
On 27 April, Greg Carter wrote: On 27 April 2012 11:39, Larry Brasfield wrote: [snip] > You "works as it should" is only assured (inasmuch as any > software can) when you use the .Net framework's assured disposition > mechanism ("using ..." and properly implemented IDispose) or effect the >

Re: [sqlite] System.Data.SQLite and pooling problem

2012-05-01 Thread Greg Carter
I do not yet have one that reproduces the problem outside of our application. I will try and see if I can come up with one. On 1 May 2012 12:48, Joe Mistachkin wrote: > > Greg Carter wrote: > > > > I tried out the changes on the tkt-996d13cd87 branch and our application

Re: [sqlite] System.Data.SQLite and pooling problem

2012-05-01 Thread Joe Mistachkin
Greg Carter wrote: > > I tried out the changes on the tkt-996d13cd87 branch and our application > runs fine with pooling on, at least for the test case that I was using to > reproduce it within our app. > Thanks! > Do you have a test case you would be willing to share? -- Joe Mistachkin

Re: [sqlite] System.Data.SQLite and pooling problem

2012-05-01 Thread Greg Carter
Hi Joe, I tried out the changes on the tkt-996d13cd87 branch and our application runs fine with pooling on, at least for the test case that I was using to reproduce it within our app. Thanks! On 30 April 2012 15:28, Joe Mistachkin wrote: > > Alexander Spence wrote: > > >

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-30 Thread Joe Mistachkin
Alexander Spence wrote: > > Btw, on an unrelated note, the is there a reason the System.Data.Sqlite source > files are not directly included by theSystem.Data.Sqlite.csproj file instead of > using a targets file? Just makes it a pain to view or make changes to the source > in visual studio. >

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-30 Thread Alexander Spence
in visual studio. -Original Message- From: sqlite-users-boun...@sqlite.org [mailto:sqlite-users-boun...@sqlite.org] On Behalf Of Joe Mistachkin Sent: Monday, April 30, 2012 2:01 PM To: 'General Discussion of SQLite Database' Subject: Re: [sqlite] System.Data.SQLite and pooling problem Alexander

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-30 Thread Joe Mistachkin
Alexander Spence wrote: > > (I'm the one that filed the Sqlite Backup API Ticket.. Actually just merged > that code in and found the access violations.) > Are you using the new backup API support in the latest System.Data.SQLite release or some custom code? > > Your fix looks a lot better than

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-30 Thread Alexander Spence
:29 PM To: 'General Discussion of SQLite Database' Subject: Re: [sqlite] System.Data.SQLite and pooling problem Joe Mistachkin wrote: > > Alexander Spence wrote: > > > > What is the purpose of these locks when Sqlite itself has been compiled as ThreadSafe? > > > >

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-30 Thread Joe Mistachkin
Joe Mistachkin wrote: > > Alexander Spence wrote: > > > > What is the purpose of these locks when Sqlite itself has been compiled as ThreadSafe? > > > > I'm not sure what the original intent of that lock was; however, after reviewing the code, > that lock does not seem to serve a useful

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-30 Thread Joe Mistachkin
Alexander Spence wrote: > > I noticed this while supporting the NFL Draft, not sure exactly how many threads were > going through the score code that was causing this exception, but the servers were > generally processing 200-300 requests per second at the time. > Just curious, were you

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-30 Thread Alexander Spence
? -Original Message- From: sqlite-users-boun...@sqlite.org [mailto:sqlite-users-boun...@sqlite.org] On Behalf Of Joe Mistachkin Sent: Saturday, April 28, 2012 9:49 PM To: 'General Discussion of SQLite Database' Subject: Re: [sqlite] System.Data.SQLite and pooling problem Alexander Spence wrote: >

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-29 Thread Joe Mistachkin
Greg Carter wrote: > > This way it's impossible for the pool to return an invalid handle. With > these changes our application runs without problems with pooling on. > Yeah, I noticed several potential race conditions when I looked at the connection pool code. However, that being said, I'm

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-29 Thread Greg Carter
On 27 April 2012 11:39, Larry Brasfield wrote: > > When you use a collection of native code from managed code, and when that > native code has cleanup to do, defined by its own conventions rather than > the conventions established for the managed code system, you

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-29 Thread Joe Mistachkin
Alexander Spence wrote: > > All of our Connections and Statements are wrapped in using statements and > being disposed correctly. I will report with more if I am able to reproduce > this with a unit test. > I've [so far] unsuccessfully attempted to reproduce this issue using release 1.0.80.0

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-28 Thread Joe Mistachkin
Alexander Spence wrote: > > I am seeing a similar error since upgrading to 1.0.80.0. I am still working on > trying to reproduce it, but here is a stack trace: > Based on your stack traces, it seems you are using the connection pool as well? How many threads are involved? Is the exception

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-28 Thread Alexander Spence
at System.ComponentModel.Component.Finalize() -Original Message- From: sqlite-users-boun...@sqlite.org [mailto:sqlite-users-boun...@sqlite.org] On Behalf Of Joe Mistachkin Sent: Friday, April 27, 2012 11:21 PM To: 'General Discussion of SQLite Database' Subject: Re: [sqlite] System.Data.SQLite and pooling problem

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-27 Thread Joe Mistachkin
Greg Carter wrote: > > We recently upgraded to 1.0.80.0 from 1.0.77.0 and have found when we turn > connection pooling on we get seemingly random memory access violations that > happen in calls to UnsafeNativeMethods.sqlite3_busy_timeout ,call stack - > Open/SetTimeout (line 259 of SQLite3.cs).

Re: [sqlite] System.Data.SQLite and pooling problem

2012-04-27 Thread Larry Brasfield
Greg Carter, on Fri Apr 27, wrote: We recently upgraded to 1.0.80.0 from 1.0.77.0 and have found when we turn connection pooling on we get seemingly random memory access violations that happen in calls to UnsafeNativeMethods.sqlite3_busy_timeout ,call stack - Open/SetTimeout (line 259 of

[sqlite] System.Data.SQLite and pooling problem

2012-04-27 Thread Greg Carter
We recently upgraded to 1.0.80.0 from 1.0.77.0 and have found when we turn connection pooling on we get seemingly random memory access violations that happen in calls to UnsafeNativeMethods.sqlite3_busy_timeout ,call stack - Open/SetTimeout (line 259 of SQLite3.cs). After compiling SQLite debug