How to implement Connection Pooling

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for MySQL
Post Reply
Posts: 1
Joined: Mon 08 May 2006 14:02

How to implement Connection Pooling

Post by romydmisc » Mon 08 May 2006 14:33

Hi Everyone,

I'm developing an application using C# .NET and mysql as database. It's a multithreaded application, we open a mysql database connection at the very beginning when the application is started and all the database requests use the same connection. But under stress or when more than one request try to access database, i get object reference errors. I don't get this error when frequency of database calls is low. Does it sounds like i need to implement connection pooling? I tried to lookup online, but couldn't find any help on mysql website. Can someone point me to documention to implement mysql connection pooling with C#.NET.

Thanks in advance,

Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Post by Alexey » Wed 10 May 2006 09:00

We do not guarantee thread safety within one connection. Use different connections and set Pooling=true to exceed performance.

Post Reply