.NET连接池 [英] .net connection pooling

查看:146
本文介绍了.NET连接池的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我不明白什么是有规律的连接和连接池之间的语法差异。

I don't get what is the syntax difference between regular connection and connection pool.

当我使用使用键,例如:

using (SqlConnection connection = new SqlConnection(connectionString))
{
    connection.Open();
    command.ExecuteNonQuery();
}

这是执行连接池的方式?

Is this the way to perform a connection pool?

推荐答案

您可以阅读有关连接池这里

You can read about connection pooling here.

基本上只要连接字符串是相同的(包括壳体),连接将取自相同的连接池。

Basically as long as the connection string is the same (including case), connections will be taken from the same connection pool.

这篇关于.NET连接池的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆