Fandango68
Fandango68

Reputation: 4898

What are the consequences of .Net connection pooling = FALSE?

According to this same question, the answer is pretty obvious: without .Net pooling on, the website has to re-connect to the database every time (every Postback time?).

However, there has to be other consequences, such as SQL memory leaks through over use of opening/closing the database without buffering?

With pooling turned OFF, does ASP.net have to recompile the ASPx/C files everytime? Plus reload all dlls?

If there are no direct and "dangerous" consequences, then I'd rather have a new connection each time and give the user better consistency of data directly from the database and not have to rely on buffers that could get corrupted. I just made that up - sorry, but really what are the real dangers?

Thank you

Upvotes: 2

Views: 405

Answers (1)

Aristos
Aristos

Reputation: 66641

From the MSDN Connection Pooling

Connecting to a data source can be time consuming. To minimize the cost of opening connections, ADO.NET uses an optimization technique called connection pooling, which minimizes the cost of repeatedly opening and closing connections. Connection pooling is handled differently for the .NET Framework data providers.

On your question " With pooling turned OFF, does ASP.net have to recompile the ASPx/C files everytime? Plus reload all dlls?" the answer is of cource not, the connection to the database have nothing to do with the compilation.

The pooling technique is transparent to your program. So also have nothing to do with SQL Memory leaks. You open and close your connection normally, and the server is handle the pooling.

Upvotes: 2

Related Questions