score:3

I'm guessing that you are keeping DataContexts around and not calling Dispose on them when done (or leaving them around, at least).

Rather, you should initialize your DataContext, perform your operation, and then dispose of it when done. You shouldn't hold a reference to it between operations.

Preferably, you would use the using statement for handling the call to IDisposable.

Regarding connection pooling, the SqlClient pools connections by default, so unless you explicitly turn it off, you should be taking advantage of it already. Of course, if you aren't releasing connections you are using, then pooling will only take you so far.


Related Articles