简体   繁体   English

MySQL .NET连接器中的连接池

[英]Connection pooling in the MySQL .NET Connector

I'm creating a website in asp.net and mysql, I noticed that the performance of connection pooling in the mysql .net connector is horrible to say the least! 我在asp.net和mysql中创建了一个网站,我注意到,至少可以这样说,在mysql .net连接器中连接池的性能令人恐惧! For example sql server is 10x times faster in connection pooling (the sql server .net provider connecting to sql server), is there anything I could do to speed up connection pooling? 例如,SQL Server在连接池中的连接速度要快10倍(连接到SQL Server的SQL Server .net提供程序),我可以做些什么来加快连接池的速度吗? Does the mysql .net connector make any checks when the connection is returned to the pool which cause the slowdown? 当连接返回到池中导致速度变慢时,mysql .net连接器是否进行任何检查?

Thanks 谢谢

Make sure that you are using the latest version of MySQL .Net Connector. 确保您使用的是最新版本的MySQL .Net Connector。 The current version is 5.2.5. 当前版本是5.2.5。

Also, the Connection String has a property Connection Lifetime (default value 0). 另外,连接字符串还具有连接寿命属性(默认值为0)。 You can try changing that value. 您可以尝试更改该值。 More information can be found here and here 更多信息可以在这里这里找到

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM